Module: wine Branch: master Commit: c08459d0be88b1663c9823b2fd57e6d0e891b242 URL: http://source.winehq.org/git/wine.git/?a=commit;h=c08459d0be88b1663c9823b2fd...
Author: Frédéric Delanoy frederic.delanoy@gmail.com Date: Mon Aug 29 21:45:16 2011 +0200
cmd/tests: Add assoc tests.
---
programs/cmd/tests/test_builtins.cmd | 30 ++++++++++++++++++++++++++++++ programs/cmd/tests/test_builtins.cmd.exp | 11 +++++++++++ 2 files changed, 41 insertions(+), 0 deletions(-)
diff --git a/programs/cmd/tests/test_builtins.cmd b/programs/cmd/tests/test_builtins.cmd index 1250e89..9dd2b60 100644 --- a/programs/cmd/tests/test_builtins.cmd +++ b/programs/cmd/tests/test_builtins.cmd @@ -1083,6 +1083,36 @@ rem Oddly windows allows file creation in a read-only directory... if exist baz\lala (echo file created in read-only dir) else echo file not created cd .. & rd /s/q foobar
+echo ------------ Testing assoc -------------- +rem FIXME Can't test error messages in the current test system, so we have to use some kludges +rem FIXME Revise once || conditional execution is fixed +mkdir foobar & cd foobar +echo ...setting association +assoc .foo > baz +type baz +echo *** + +assoc .foo=bar +assoc .foo + +rem association set system-wide +echo @echo off> tmp.cmd +echo echo +++>> tmp.cmd +echo assoc .foo>> tmp.cmd +cmd /c tmp.cmd + +echo ...resetting association +assoc .foo= +assoc .foo > baz +type baz +echo *** + +rem association removal set system-wide +cmd /c tmp.cmd > baz +type baz +echo *** +cd .. & rd /s/q foobar + echo ------------ Testing CALL -------------- mkdir foobar & cd foobar rem External script diff --git a/programs/cmd/tests/test_builtins.cmd.exp b/programs/cmd/tests/test_builtins.cmd.exp index 5c545ed..1e393f3 100644 --- a/programs/cmd/tests/test_builtins.cmd.exp +++ b/programs/cmd/tests/test_builtins.cmd.exp @@ -654,6 +654,17 @@ Read-only file forcibly deleted toto lulu file created in read-only dir +------------ Testing assoc -------------- +...setting association +*** +.foo=bar +@todo_wine@.foo=bar ++++ +@todo_wine@.foo=bar +...resetting association +*** ++++ +*** ------------ Testing CALL -------------- foo@space@ foo 8