diff options
Diffstat (limited to 'test/ninja/copy_function_command.py')
-rw-r--r-- | test/ninja/copy_function_command.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/test/ninja/copy_function_command.py b/test/ninja/copy_function_command.py index a1e72b7..06991d3 100644 --- a/test/ninja/copy_function_command.py +++ b/test/ninja/copy_function_command.py @@ -26,6 +26,7 @@ __revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__" import os import TestSCons +from TestCmd import IS_WINDOWS _python_ = TestSCons._python_ _exe = TestSCons._exe @@ -50,14 +51,14 @@ env.Program(target = 'foo', source = 'foo2.c') test.run(stdout=None) test.must_contain_all_lines(test.stdout(), ['Generating: build.ninja', 'Executing: build.ninja']) -test.run(program = test.workpath('foo'), stdout="foo.c" + os.linesep) +test.run(program = test.workpath('foo'), stdout="foo.c") # clean build and ninja files test.run(arguments='-c', stdout=None) test.must_contain_all_lines(test.stdout(), [ 'Removed foo2.o', 'Removed foo2.c', - 'Removed foo', + 'Removed foo' + _exe, 'Removed build.ninja']) # only generate the ninja file @@ -68,8 +69,9 @@ test.must_not_contain_any_line(test.stdout(), ['Executing: build.ninja']) # run ninja independently -test.run(program = ninja, stdout=None) -test.run(program = test.workpath('foo'), stdout="foo.c" + os.linesep) +program = ['ninja_env.bat', '&', ninja] if IS_WINDOWS else ninja +test.run(program = program, stdout=None) +test.run(program = test.workpath('foo'), stdout="foo.c") test.pass_test() |