diff options
author | Steven Knight <knight@baldmt.com> | 2003-12-01 13:06:29 (GMT) |
---|---|---|
committer | Steven Knight <knight@baldmt.com> | 2003-12-01 13:06:29 (GMT) |
commit | 25421966e18737ffc349b007d104c53cc4bb88fb (patch) | |
tree | 6f7aaa5f6e05039884cb82deafa9a4f99b3682a7 /test | |
parent | 32caf226be9a3732a8f7f484e39cb1e67582988f (diff) | |
download | SCons-25421966e18737ffc349b007d104c53cc4bb88fb.zip SCons-25421966e18737ffc349b007d104c53cc4bb88fb.tar.gz SCons-25421966e18737ffc349b007d104c53cc4bb88fb.tar.bz2 |
Make the message about missing SConscript files a warning, not a hard write(), so it can be ignored/disabled. (Scott Fritchie)
Diffstat (limited to 'test')
-rw-r--r-- | test/option--warn.py | 17 | ||||
-rw-r--r-- | test/option-f.py | 6 |
2 files changed, 22 insertions, 1 deletions
diff --git a/test/option--warn.py b/test/option--warn.py index aa970fe..c8e16a9 100644 --- a/test/option--warn.py +++ b/test/option--warn.py @@ -82,4 +82,21 @@ scons: warning: No dependency generated for file: not_there\.h \(included from: File ".+", line \d+, in .+ """) +test.write("SConstruct", """\ +def build(target, source, env): + pass + +env=Environment() +env['BUILDERS']['test'] = Builder(action=build) +env.test(target='foo', source='foo.c') +SConscript('no_such_file') +""") + +test.run(arguments = '--warn=missing-sconscript .', stderr = r""" +scons: warning: Ignoring missing SConscript 'no_such_file' +File ".+", line \d+, in .+ +""") + +test.run(arguments = '--warn=no-missing-sconscript .', stderr = "") + test.pass_test() diff --git a/test/option-f.py b/test/option-f.py index 2001a06..3c8dcee 100644 --- a/test/option-f.py +++ b/test/option-f.py @@ -86,6 +86,10 @@ print "STDIN " + os.getcwd() test.run(arguments = '-f no_such_file .', stdout = test.wrap_stdout("scons: `.' is up to date.\n"), - stderr = "Ignoring missing SConscript 'no_such_file'\n") + stderr = None) +test.fail_test(not test.match_re(test.stderr(), """ +scons: warning: Ignoring missing SConscript 'no_such_file' +File "\S+", line \d+, in .* +""")) test.pass_test() |