
==testScriptVarAccess()==
A scriptvariable is copied locally, changes are effective only locally.
But if jzcmd.scriptVariables().scriptString is set, it is effective in the script:

Text in a script variable: scriptString = scriptStringFirst
Changed: scriptString = new text
In other method: scriptString = scriptStringFirst
In other method: scriptString = changed on script level

==testBatch()==
This example creates an batchfile and executes it then. It works for MS-Windows.
The batch 'myBatch.bat' contains a 'dir' cmd which's output is redirected in a newly created text file 'out.txt'.
After execution this JZcmd subroutine evaluates the 'out.txt'.
It searches in the line containing 'myBatch' in the and shows it.

===Variantes of currdir: ===
jzcmd.scriptLevel.currdir = D:\vishia\ZBNF\sf\ZBNF\examples_JZcmd\TestAll
jzcmd.currdir() = D:/vishia/ZBNF/sf/ZBNF/examples_JZcmd/TestAll
jzcmdsub.currdir = D:\vishia\ZBNF\sf\ZBNF\examples_JZcmd
jzcmdsub.currdir = D:/vishia/ZBNF/sf/ZBNF/examples_JZcmd

executes myBatch.bat, creates out.txt in the current directory ...
evaluates 'out.txt': 15.05.2015  08:12                43 myBatch.bat

==testErrorlevel()==
testErrorlevel(): 1 < 5 
testErrorlevel(): 2 < 5 
testErrorlevel(): 2 >= 2 
testErrorlevel(): 3 < 5 
testErrorlevel(): 3 >= 2 
testErrorlevel(): exeception handling 

==testOutputTextIndent()==
First line left aligned
Second line left aligned
Third line left aligned
  forth line 2 spaces, continue of forth line, one space
fifth line left aligned.

==testDebugErrorMsg()==
Variable not exists: Any error in 'testDebugErrorMsg': java.lang.NoSuchFieldException: faultyVariable; in statement:  @D:/vishia/ZBNF/sf/ZBNF/examples_JZcmd/TestAll/testAll.jz.bat:164,28; e <*)

==testErrorToOutput()==
unknown variable: <?? java.lang.NoSuchFieldException: unknown; in statement:  @D:/vishia/ZBNF/sf/ZBNF/examples_JZcmd/TestAll/testAll.jz.bat:187,25; e <*) ??>
unknown variable: there is an error: java.lang.NoSuchFieldException: unknown; in statement:  @D:/vishia/ZBNF/sf/ZBNF/examples_JZcmd/TestAll/testAll.jz.bat:189,25; e <*)
The error with stacktrace: JZcmd.execute - exception at; @D:/vishia/ZBNF/sf/ZBNF/examples_JZcmd/TestAll/testAll.jz.bat:189,25; e <*);java.lang.NoSuchFieldException: unknown; org.vishia.util.DataAccess.getData(DataAccess.java:1496); org.vishia.util.DataAccess.access(DataAccess.java:884); org.vishia.cmd.JZcmdExecuter$ExecuteLevel.dataAccess(JZcmdExecuter.java:2330); org.vishia.cmd.JZcmdExecuter$ExecuteLevel.executeDatatext(JZcmdExecuter.java:1916); org.vishia.cmd.JZcmdExecuter$ExecuteLevel.execute(JZcmdExecuter.java:920); org.vishia.cmd.JZcmdExecuter$ExecuteLevel.textAppendToVar(JZcmdExecuter.java:1419); org.vishia.cmd.JZcmdExecuter$ExecuteLevel.execute(JZcmdExecuter.java:873); org.vishia.cmd.JZcmdExecuter$ExecuteLevel.execSubroutine(JZcmdExecuter.java:1639); org.vishia.cmd.JZcmdExecuter$ExecuteLevel.execCall(JZcmdExecuter.java:1473); org.vishia.cmd.JZcmdExecuter$ExecuteLevel.execute(JZcmdExecuter.java:921); org.vishia.cmd.JZcmdExecuter$ExecuteLevel.access$0(JZcmdExecuter.java:837); org.vishia.cmd.JZcmdExecuter.execute(JZcmdExecuter.java:553); org.vishia.zcmd.JZcmd.execute(JZcmd.java:557); org.vishia.zcmd.JZcmd.execute(JZcmd.java:526); org.vishia.zcmd.JZcmd.smain(JZcmd.java:323); org.vishia.zcmd.JZcmd.main(JZcmd.java:246); 


test throw...
error throw: org.vishia.cmd.JZcmdExecuter$JZcmdThrow: text; in statement:  @D:/vishia/ZBNF/sf/ZBNF/examples_JZcmd/TestAll/testAll.jz.bat:196,7; r

==TestErrorSub.test()==
TestErrorSub - onerror reached: java.lang.NoSuchFieldException: nonexistVariable; in statement:  @D:/vishia/ZBNF/sf/ZBNF/examples_JZcmd/TestAll/testAll.jz.bat:206,11; S Defvariable [xx:S] 
==TestExceptionInException==
TestExceptionInException with errorneous: An inner onerror catches the error in an error handling: java.lang.NoSuchFieldException: unknownVariable; in statement:  @D:/vishia/ZBNF/sf/ZBNF/examples_JZcmd/TestAll/testAll.jz.bat:230,53; e <*)
Second error is not catched: An onerror block in an outer routine should be correct: java.lang.NoSuchFieldException: unknownVariable; in statement:  @D:/vishia/ZBNF/sf/ZBNF/examples_JZcmd/TestAll/testAll.jz.bat:238,40; e <*)

==testDataAccess()==
Text in a user Java instance: scriptObj.simpleTestString = the simple test string.
Changed scriptObj.simpeTestString = "new text"; result = new text

==testMethodInvoke()==
file=D:\vishia\ZBNF\sf\ZBNF\examples_JZcmd\TestAll\myFile
file=D:\vishia\ZBNF\sf\ZBNF\examples_JZcmd\TestAll\path\myFile.ext
char=x, text=text
char=a
char=a
char=a
char=a
text=a
text=content of org.vishia.zcmd.JZcmdUserExample@2983bd71

==testCalctime()==
Start...
Time = J 1113 ms. 

==testVariableDatapath()==
valB
valB

==testText()==
