You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
boxgaming edited this page Jul 11, 2026
·
1 revision
Used to verify that a given condition is true. If not, an error is thrown and execution is stopped.
The line containing the assertion error will be shown in the console output. Available in release 0.11.0
Syntax
UT.AssertTruevalue
Parameters
The value parameter contains the variable or expression to test.
Example
Import UT From "lib/test/unit-test.bas"DimiAs Integeri = 23
UT.AssertTrue i < 23
UT.AssertTrue i > 30
Output
ERROR : 7 : false is not true
Error: false is not true
at Object.sub_AssertTrue (eval at _runProgram (http://localhost:8080/qbjs-ide.js:434:26), <anonymous>:27:29)
at main (eval at _runProgram (http://localhost:8080/qbjs-ide.js:434:26), <anonymous>:58:13)
at async eval (eval at _runProgram (http://localhost:8080/qbjs-ide.js:434:26), <anonymous>:61:3)
at async Object._runProgram [as runProgram] (http://localhost:8080/qbjs-ide.js:435:13)