diff options
author | Steven Knight <knight@baldmt.com> | 2001-09-15 13:46:11 (GMT) |
---|---|---|
committer | Steven Knight <knight@baldmt.com> | 2001-09-15 13:46:11 (GMT) |
commit | fcd916513a1ad10e13479d4d604f239f7ea45c73 (patch) | |
tree | 4ddf60867e13b0ba12f5b37c6a4eaebc9a08ebaa /test/option-f.py | |
parent | f4b5ccd3fdacad36cb124245591ea5bfaf4de12e (diff) | |
download | SCons-fcd916513a1ad10e13479d4d604f239f7ea45c73.zip SCons-fcd916513a1ad10e13479d4d604f239f7ea45c73.tar.gz SCons-fcd916513a1ad10e13479d4d604f239f7ea45c73.tar.bz2 |
Add a TestSCons module for common initialization of SCons tests.
Diffstat (limited to 'test/option-f.py')
-rw-r--r-- | test/option-f.py | 26 |
1 files changed, 12 insertions, 14 deletions
diff --git a/test/option-f.py b/test/option-f.py index b9dbd75..81120d1 100644 --- a/test/option-f.py +++ b/test/option-f.py @@ -2,12 +2,10 @@ __revision__ = "test/option-f.py __REVISION__ __DATE__ __DEVELOPER__" -import TestCmd +import TestSCons import os.path -test = TestCmd.TestCmd(program = 'scons.py', - workdir = '', - interpreter = 'python') +test = TestSCons.TestSCons() test.subdir('subdir') @@ -25,46 +23,46 @@ print "subdir/BuildThis", os.getcwd() wpath = test.workpath() -test.run(chdir = '.', arguments = '-f SConscript') +test.run(arguments = '-f SConscript') test.fail_test(test.stdout() != ("SConscript %s\n" % wpath)) test.fail_test(test.stderr() != "") -test.run(chdir = '.', arguments = '-f ' + subdir_BuildThis) +test.run(arguments = '-f ' + subdir_BuildThis) test.fail_test(test.stdout() != ("subdir/BuildThis %s\n" % wpath)) test.fail_test(test.stderr() != "") -test.run(chdir = '.', arguments = '--file=SConscript') +test.run(arguments = '--file=SConscript') test.fail_test(test.stdout() != ("SConscript %s\n" % wpath)) test.fail_test(test.stderr() != "") -test.run(chdir = '.', arguments = '--file=' + subdir_BuildThis) +test.run(arguments = '--file=' + subdir_BuildThis) test.fail_test(test.stdout() != ("subdir/BuildThis %s\n" % wpath)) test.fail_test(test.stderr() != "") -test.run(chdir = '.', arguments = '--makefile=SConscript') +test.run(arguments = '--makefile=SConscript') test.fail_test(test.stdout() != ("SConscript %s\n" % wpath)) test.fail_test(test.stderr() != "") -test.run(chdir = '.', arguments = '--makefile=' + subdir_BuildThis) +test.run(arguments = '--makefile=' + subdir_BuildThis) test.fail_test(test.stdout() != ("subdir/BuildThis %s\n" % wpath)) test.fail_test(test.stderr() != "") -test.run(chdir = '.', arguments = '--sconstruct=SConscript') +test.run(arguments = '--sconstruct=SConscript') test.fail_test(test.stdout() != ("SConscript %s\n" % wpath)) test.fail_test(test.stderr() != "") -test.run(chdir = '.', arguments = '--sconstruct=' + subdir_BuildThis) +test.run(arguments = '--sconstruct=' + subdir_BuildThis) test.fail_test(test.stdout() != ("subdir/BuildThis %s\n" % wpath)) test.fail_test(test.stderr() != "") -test.run(chdir = '.', arguments = '-f -', stdin = """ +test.run(arguments = '-f -', stdin = """ import os print "STDIN " + os.getcwd() """) test.fail_test(test.stdout() != ("STDIN %s\n" % wpath)) test.fail_test(test.stderr() != "") -test.run(chdir = '.', arguments = '-f no_such_file') +test.run(arguments = '-f no_such_file') test.fail_test(test.stdout() != "") test.fail_test(test.stderr() != "Ignoring missing script 'no_such_file'\n") |