2 @pwd@>echo Tests for cmd's builtin commands@space@
3 Tests for cmd's builtin commands
5 @pwd@>echo ------------ Testing 'echo' [ON] --------------@space@
6 ------------ Testing 'echo' [ON] --------------
11 @pwd@>echo 'singlequotedword'@space@
14 @pwd@>echo "doublequotedword"@space@
18 @pwd@>echo "/?"@space@
30 @pwd@>echo .word@space@
42 @pwd@>echo :word@space@
45 @pwd@>echo word@space@@space@
48 @pwd@>echo word@space@@space@@space@
50 ------------ Testing 'echo' [OFF] --------------
66 ------------ Testing redirection operators --------------
82 @todo_wine@foob@space@
83 @todo_wine@fooc@space@
87 @todo_wine@------------ Testing ^ escape character --------------
88 @todo_wine@hello, world
89 @todo_wine@hello, world
90 @todo_wine@hell^o, world
91 @todo_wine@hell^o, world
94 @todo_wine@foo | echo bar
95 @todo_wine@foo & echo bar
98 @todo_wine@0@or_broken@1
102 @todo_wine@FOO=bar | baz
104 @todo_wine@FOO=bar ^| baz
107 ------------ Testing 'set' --------------
117 @todo_wine@FOOBAR= bar
118 @todo_wine@FOOBAR = baz2
127 set "FOO=bar" should not include the quotes in the variable value
129 ------------ Testing variable expansion --------------
130 ~dp0 should be directory containing batch file
133 CD value @pwd@@or_broken@CD value@space@
149 ------------ Testing variable delayed expansion --------------
150 ...default mode (load-time expansion)
155 ...runtime (delayed) expansion mode
157 @todo_wine@foo@or_broken@!FOO!
159 @todo_wine@bar@or_broken@foo
166 @todo_wine@foo@or_broken@!FOO!
169 ------------ Testing conditional execution --------------
170 @todo_wine@...unconditional &
174 @todo_wine@foobar deleted
175 @todo_wine@...on success conditional &&
176 @todo_wine@foo3 not created
179 @todo_wine@...on failure conditional ||
181 @todo_wine@foo6@space@
182 ------------ Testing type ------------
184 @pwd@>type foobaz@space@
187 @pwd@>echo ***@space@
191 ------------ Testing NUL ------------
196 @todo_wine@foo created
197 ------------ Testing if/else --------------
198 if/else should work with blocks
201 @todo_wine@if seems not to detect /c as parameter
202 Testing case sensitivity with and without /i option
203 if seems to default to case sensitivity
206 -----------Testing for -----------
255 @todo_wine@ErrorLevel 0
256 @todo_wine@ErrorLevel 0
258 ......individual operations
274 0@or_broken@1073741824
275 0@or_broken@-1073741824
296 ......precedence and grouping
299 @todo_wine@18@or_broken@10
300 @todo_wine@2@or_broken@0
301 @todo_wine@2@or_broken@0
304 @todo_wine@3@or_broken@4
305 ......octal and hexadecimal
306 @todo_wine@3@or_broken@4
312 @todo_wine@3@or_broken@foo not defined
313 @todo_wine@3@or_broken@0
314 @todo_wine@3@or_broken@0
315 @todo_wine@3@or_broken@0
316 @todo_wine@9@or_broken@0
318 @todo_wine@4@or_broken@0
319 @todo_wine@-7@or_broken@0
320 @todo_wine@-1@or_broken@0
321 @todo_wine@5@or_broken@0
322 @todo_wine@4@or_broken@0
323 @todo_wine@1@or_broken@0
325 @todo_wine@5@or_broken@0
327 -----------Testing del /a-----------
328 not-r.test not found after delete, good
329 r.test found before delete, good
330 r.test not found after delete, good
331 ------------ Testing del /q --------------
332 del /q * succeeded on file1
333 del /q * succeeded on file2.dat
334 ------------ Testing del /s --------------
335 ----------- Testing mkdir -----------
351 mkdir ? gives errorlevel 1
352 mkdir ?\foo gives errorlevel 1
353 mkdir foo\? gives errorlevel 1
355 mkdir foo\bar\? gives errorlevel 1
361 mkdir foo\* errorlevel 1
363 ----------- Testing rmdir -----------
372 non-empty dir not removed
374 non-empty dir not removed
375 recursive rmdir succeeded
376 recursive rmdir succeeded
381 ------------ Testing CALL --------------
386 @todo_wine@foo ""@space@
387 @todo_wine@"" bar@space@
398 @todo_wine@foo created
399 @todo_wine@Should expand foobaz
405 ------------ Testing setlocal/endlocal ------------
406 ...enable/disable extensions
407 @todo_wine@ErrLev:@space@
410 @todo_wine@ErrLev:@space@@or_broken@ErrLev: 0
412 ...setlocal with corresponding endlocal
417 ...setlocal with no corresponding endlocal
421 -----------Testing Errorlevel-----------
424 errorlevel just right, good
425 abc0def@or_broken@abc1def
426 errorlevel zero, good@or_broken@errorlevel nonzero, bad
429 -----------Testing GOTO-----------
430 goto with no leading space worked
431 goto with a leading space worked
432 goto with a leading tab worked
433 goto with a following space worked
434 -----------Done, jumping to EOF-----------