Module: wine Branch: master Commit: ce57ebe32dfcad4556d1e0db1958067ce8326e4f URL: http://source.winehq.org/git/wine.git/?a=commit;h=ce57ebe32dfcad4556d1e0db19... Author: Frédéric Delanoy <frederic.delanoy(a)gmail.com> Date: Fri Jul 29 13:59:51 2011 +0200 cmd/tests: Additional CALL tests. --- programs/cmd/tests/test_builtins.cmd | 20 ++++++++++++++++++++ programs/cmd/tests/test_builtins.cmd.exp | 12 ++++++++++++ 2 files changed, 32 insertions(+), 0 deletions(-) diff --git a/programs/cmd/tests/test_builtins.cmd b/programs/cmd/tests/test_builtins.cmd index f3b1fc5..04d8fdd 100644 --- a/programs/cmd/tests/test_builtins.cmd +++ b/programs/cmd/tests/test_builtins.cmd @@ -542,6 +542,13 @@ rem External script echo echo foo %%1> foo.cmd call foo call foo.cmd 8 +echo echo %%1 %%2 > foo.cmd +call foo.cmd foo +call foo.cmd foo bar +call foo.cmd foo "" +call foo.cmd "" bar +call foo.cmd foo '' +call foo.cmd '' bar del foo.cmd rem Internal routines call :testRoutine :testRoutine @@ -550,6 +557,19 @@ goto :endTestRoutine echo bar %1 goto :eof :endTestRoutine + +call :testRoutineArgs foo +call :testRoutineArgs foo bar +call :testRoutineArgs foo "" +call :testRoutineArgs "" bar +call :testRoutineArgs foo '' +call :testRoutineArgs '' bar +goto :endTestRoutineArgs +:testRoutineArgs +echo %1 %2 +goto :eof +:endTestRoutineArgs + rem Should work for builtins... call mkdir foo echo %ErrorLevel% diff --git a/programs/cmd/tests/test_builtins.cmd.exp b/programs/cmd/tests/test_builtins.cmd.exp index 51239b0..d7ac58a 100644 --- a/programs/cmd/tests/test_builtins.cmd.exp +++ b/programs/cmd/tests/test_builtins.cmd.exp @@ -288,7 +288,19 @@ bar\baz removed ------------ Testing CALL -------------- foo(a)space@ @todo_wine(a)foo 8 +foo(a)space@@space@ +foo bar(a)space@ +(a)todo_wine@foo ""@space@ +(a)todo_wine@"" bar(a)space@ +foo ''@space@ +'' bar(a)space@ bar :testRoutine +foo(a)space@ +foo bar +(a)todo_wine@foo "" +(a)todo_wine@"" bar +foo '' +'' bar @todo_wine(a)0 @todo_wine(a)foo created @todo_wine(a)Should expand foobaz