Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

Squirrel 3.1 and new bindings

<< < (2/7) > >>

oBFusCATed:
Some OS related test failures are expected. The string comparison failures aren't. :shrug:

p.s. I hate PCHs, such a stupid idea.

ollydbg:
I use Tim's patches, thanks Tim!


--- Quote from: oBFusCATed on April 17, 2021, 05:48:35 pm ---Are you able to run the tests?
Steps:
1. Show the script console
2. Load the src/scripts/tests/script_test_plugin.script

--- End quote ---

Here is my result:

--- Code: ---Welcome to the script console!
Plugin instance: (instance : 0x0000000005E8B190)
======= Test Test environment BEGINN =======
 this is intended to fail:
[ERROR] Test: test_string...................FAILED
[ERROR] got:    "hallo"
[ERROR] needed: "nope "

Executed tests: 1
passed tests:   0
failed tests:   1
======= Test Test environment END =======
======= Test wx String BEGINN =======
Test: tostring......................PASSED
Test: constructor(SQchar)...........PASSED
Test: cmp...........................PASSED
Test: cmp not.......................PASSED
Test: cmp string....................PASSED
Test: cmp string2...................PASSED
Test: cmp string not................PASSED
Test: cmp string not2...............PASSED
Test: Compare.......................PASSED
Test: Compare lt....................PASSED
Test: Compare gt....................PASSED
Test: Compare lt string.............PASSED
Test: Compare gt string.............PASSED
Test: _add..........................PASSED
Test: _add wxString+string..........PASSED
Test: _add string+wxString..........PASSED
Test: _add wxString+int.............PASSED
Test: _add wxString+float...........PASSED
Test: _cloned.......................PASSED
Test: IsEmpty.......................PASSED
Test: IsEmpty.......................PASSED
Test: Length........................PASSED
Test: length........................PASSED
Test: len...........................PASSED
Test: size..........................PASSED
Test: Lower.........................PASSED
Test: LowerCase.....................PASSED
Test: MakeLower.....................PASSED
Test: Upper.........................PASSED
Test: UpperCase.....................PASSED
Test: MakeUpper.....................PASSED
Test: Mid...........................PASSED
Test: Remove........................PASSED
Test: RemoveLast....................PASSED
Test: Replace ret...................PASSED
Test: Replace value.................PASSED
Test: AfterFirst....................PASSED
Test: AfterFirst str................PASSED
Test: AfterLast.....................PASSED
Test: AfterLast str.................PASSED
Test: BeforeFirst...................PASSED
Test: BeforeFirst str...............PASSED
Test: BeforeLast....................PASSED
Test: BeforeLast str................PASSED
Test: Right.........................PASSED
Test: Left..........................PASSED
Test: Matches.......................PASSED
Test: Find..........................PASSED
Test: Find not......................PASSED
Test: AddChar 'D'...................PASSED
Test: GetChar 0.....................PASSED
Test: Assignment 0..................PASSED
Test: Assignment 1..................PASSED
Test: Set 0.........................PASSED
Test: Set 1.........................PASSED
Test: ConcatNull....................PASSED
Test: wxString_ToLong good..........PASSED
Test: wxString_ToLong bad...........PASSED

Executed tests: 56
passed tests:   58
failed tests:   0
======= Test wx String END =======
======= Test wx String unicode BEGINN =======
[ERROR] Test: This implementation doesn't support UNICODE...MADE-FAILED
[ERROR] not implemented, as you can see on the wrong test string (it has to show Cyrillic  and ?Japanese? symbols

Executed tests: 0
passed tests:   0
failed tests:   1
======= Test wx String unicode END =======
======= Test wx Color BEGINN =======
Test: Set...........................PASSED
Test: tostring......................PASSED
Test: _cloned.......................PASSED
Test: Red...........................PASSED
Test: Green.........................PASSED
Test: Blue..........................PASSED
Test: IsOK..........................PASSED

Executed tests: 7
passed tests:   7
failed tests:   0
======= Test wx Color END  =======
======= Test wxArrayString BEGINN =======
Test: constructor...................PASSED
Test: Add wxString..................PASSED
Test: GetCount......................PASSED
Test: Index("String1")..............PASSED
Test: Index("String10").............PASSED
Test: Index("string1",true,false)...PASSED
Test: Index("string1",false,false)..PASSED
Test: Index("string2",false,false)..PASSED
Test: Index("string2",false,true)...PASSED
Test: Item..........................PASSED
Test: _cloned.......................PASSED
itemValue='String2 modified'; newValue='String2 modified'
Test: Item after modify.............PASSED
Test: SetItem.......................PASSED
Test: SetItem.......................PASSED
Test: SetItem old ref...............PASSED
Test: Clear.........................PASSED

Executed tests: 15
passed tests:   16
failed tests:   0
======= Test wxArrayString END  =======
======= Test wxFileName BEGINN =======
Test: constructor...................PASSED
Use path: \share\codeblocks\
Test: tostring......................PASSED
Test: _cloned.......................PASSED
Test: Assign........................PASSED
Test: GetDirCount...................PASSED
Test: GetDirs.......................PASSED
Test: Clear.........................PASSED
Test: AssignDir.....................PASSED
Test: AssignCwd = D:\code\cbsource\script31\src\output31_64\
Test: AssignCwd ????................PASSED
Test: GetCwd = D:\code\cbsource\script31\src\output31_64
Test: GetCwd ????...................PASSED
Test: AssignHomeDir = C:\Users\Administrator\
Test: AssignHomeDir ????............PASSED
Test: GetExt........................PASSED
Test: GetFullName...................PASSED
Test: GetFullPath...................PASSED
Test: GetLongPath = share\CodeBlocks\tips.txt
Test: GetLongPath ????..............PASSED
Test: GetName.......................PASSED
Test: GetPath = \share\codeblocks
Test: GetPath ????..................PASSED
Test: GetShortPath = \share\codeblocks\tips.txt
Test: GetShortPath ????.............PASSED
Test: GetVolume = 
Test: GetVolume ????................PASSED
Test: HasExt........................PASSED
Test: HasExt not (after ClearExt)...PASSED
Test: HasName.......................PASSED
[ERROR] Test: HasVolume.....................FAILED
[ERROR] got:    false
[ERROR] needed: true
Test: IsAbsolute....................PASSED
Test: IsOk..........................PASSED
Test: IsRelative....................PASSED
Test: IsDir.........................PASSED
Test: GetFullName...................PASSED
Test: GetFullPath...................PASSED
Test: InsertDir.....................PASSED
[ERROR] Test: InsertDir value...............FAILED
[ERROR] got:    "\newdir\share\codeblocks\"
[ERROR] needed: "newdir\\share\codeblocks\ "
Test: PrependDir....................PASSED
[ERROR] Test: PrependDir value..............FAILED
[ERROR] got:    "\newdir\share\codeblocks\"
[ERROR] needed: "newdir\\share\codeblocks\ "
Test: RemoveDir.....................PASSED
Test: AppendDir.....................PASSED
Test: AppendDir value...............PASSED
Test: MakeAbsolute..................PASSED
[ERROR] Test: MakeAbsolute value............FAILED
[ERROR] got:    "C:\share\codeblocks\tips.txt"
[ERROR] needed: "C:\Users\Administrator\\share\codeblocks\tips.txt "
Test: MakeRelativeTo................PASSED
[ERROR] Test: MakeRelativeTo value..........FAILED
[ERROR] got:    "..\..\share\codeblocks\tips.txt"
[ERROR] needed: "\share\codeblocks\tips.txt "
Test: Normalize.....................PASSED
[ERROR] Test: Normalize value...............FAILED
[ERROR] got:    "C:\share\codeblocks\tips.txt"
[ERROR] needed: "C:\Users\Administrator\\share\codeblocks\tips.txt "
Test: SameAs equal..................PASSED
Test: SameAs not equal..............PASSED
Test: SetExt........................PASSED
Test: SetEmptyExt...................PASSED
Test: SetEmptyExt has...............PASSED
Test: SetFullName...................PASSED
Test: SetName.......................PASSED
[ERROR] Test: SetVolume.....................FAILED
[ERROR] got:    "\\afterName\share\codeblocks\afterName.my"
[ERROR] needed: "\share\codeblocks\afterName.my "

Executed tests: 42
passed tests:   43
failed tests:   7
======= Test wxFileName END  =======
======= Test wxPoint BEGINN =======
Test: compare gt....................PASSED
Test: compare gt....................PASSED
Test: compare lt....................PASSED
Test: compare lt....................PASSED
Test: Cmp...........................PASSED
Test: Cmp not.......................PASSED
Test: _tostring.....................PASSED
Test: _cloned.......................PASSED

Executed tests: 8
passed tests:   8
failed tests:   0
======= Test wxPoint END  =======
======= Test wxSize BEGINN =======
Test: _tostring.....................PASSED
Test: _cloned.......................PASSED
Test: GetWidth......................PASSED
Test: GetHeight.....................PASSED
Test: SetWidth......................PASSED
Test: SetHeight.....................PASSED

Executed tests: 6
passed tests:   6
failed tests:   0
======= Test wxSize END  =======

Global executed tests: 146
Global passed tests:   138
Global failed tests:   9
Script loaded successfully

--- End code ---



--- Quote ---3. Plugins -> Test scripting -> Test wx or Test sdk

--- End quote ---

I think the "Test wx" result is the same as the step 2.

Here is the Test sdk result: when after testing, there is a warning message box:
" Couldn't save project C:\Users\ADMINI~1\AppData\Local\Temp\sdk_tests\NewProjects.cbp (Maybe the file is write-protected?)"

The log contents are too big to paste here, so I upload as attachment.

BTW: I'm using the portable mode to start the C::B,

--- Code: ---start cblauncher.exe --debug-log --no-dde --no-check-associations --multiple-instance --no-splash-screen

--- End code ---
but it looks like it still use some global folders.

BlueHazzard:
I have run the wrong tests...

For wx i get the same results as ollydbg...

for sdk i got some write permission errors like ollydbg and at the end some crash:

--- Code: ---error:
error: AN ERROR HAS OCCURED [the index 'SetModified' does not exist]
error:
error: CALLSTACK
error: *FUNCTION [test_classes()] C:\Users\XXXXX\codeblocks_git_obfuscated\src\scripts\tests/sdk_test.script line [1353]
error: *FUNCTION [Run()] C:\Users\XXXXX\Documents\src\scripts\tests/sdk_test.script line [14]
error: *FUNCTION [StartSDKTest()] C:\Users\XXXXX\codeblocks_git_obfuscated\src\scripts\tests\script_test_plugin.script line [90]
error: *FUNCTION [OnMenuClicked()] C:\Users\XXXXX\codeblocks_git_obfuscated\src\scripts\tests\script_test_plugin.script line [62]
error:
error: LOCALS
error: [editor1Filename] INSTANCE
error: [editor0Filename] INSTANCE
error: [editor1] NULL
error: [editor0] INSTANCE
error: [editorMgr] INSTANCE
error: [tempFolder] INSTANCE
error: [this] INSTANCE
error: [this] INSTANCE
error: [sdk] INSTANCE
error: [this] INSTANCE
error: [index] 1
error: [this] INSTANCE

--- End code ---

exactly as ollydbg ...

sry about the noise...

oBFusCATed:
The tests are not really windows proofed. Either I have to find a windows machine or someone else to volunteer to try and fix them.

oBFusCATed:
I've applied a modified version of the stahta01, please let me know if they work.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version