From: stevenknight Date: Sat, 28 Nov 2009 04:52:19 +0000 (+0000) Subject: Don't hard-code the swig location in the expected output. X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=f5e1a359c158eab7de5a70d6d4293650e9f3d60e;p=scons.git Don't hard-code the swig location in the expected output. Use test.wrap_stdout() instead of hard-coding the SCons messages. git-svn-id: http://scons.tigris.org/svn/scons/trunk@4492 fdb21ef1-2011-0410-befe-b5e4ea1792b1 --- diff --git a/test/SWIG/generated_swigfile.py b/test/SWIG/generated_swigfile.py index 844f7868..1187df22 100644 --- a/test/SWIG/generated_swigfile.py +++ b/test/SWIG/generated_swigfile.py @@ -49,7 +49,6 @@ else: _dll = '.so' test = TestSCons.TestSCons() -test.verbose_set(1) swig = test.where_is('swig') if not swig: @@ -77,16 +76,13 @@ java_c_file = foo.CFile( target='java_swig_test' ,source=java_interface, SW """ % locals()) -expected_stdout = """scons: Reading SConscript files ... -scons: done reading SConscript files. -scons: Building targets ... -echo '%module test_java_swig' > test_java_swig.i -/usr/bin/swig -o java_swig_test_wrap.cc -java -c++ test_java_swig.i -echo '%module test_py_swig' > test_py_swig.i -/usr/bin/swig -o python_swig_test_wrap.cc -python -c++ test_py_swig.i -scons: done building targets. -""" -test.run(arguments = '.',stdout=expected_stdout) +expected_stdout = """\ +echo '%%module test_java_swig' > test_java_swig.i +%(swig)s -o java_swig_test_wrap.cc -java -c++ test_java_swig.i +echo '%%module test_py_swig' > test_py_swig.i +%(swig)s -o python_swig_test_wrap.cc -python -c++ test_py_swig.i +""" % locals() +test.run(arguments = '.',stdout=test.wrap_stdout(expected_stdout)) # If we mistakenly depend on the .py file that SWIG didn't create