diff options
Diffstat (limited to 'test/Configure')
-rw-r--r-- | test/Configure/ConfigureDryRunError.py | 16 | ||||
-rw-r--r-- | test/Configure/option--config.py | 9 |
2 files changed, 16 insertions, 9 deletions
diff --git a/test/Configure/ConfigureDryRunError.py b/test/Configure/ConfigureDryRunError.py index 04fbc75..65c6403 100644 --- a/test/Configure/ConfigureDryRunError.py +++ b/test/Configure/ConfigureDryRunError.py @@ -57,20 +57,24 @@ if not (r1 and not r2): Exit(1) """ % (lib)) -test.run(arguments='-n', status=2, stderr=""" +expect = """ scons: *** Cannot create configure directory ".sconf_temp" within a dry-run. -File "%(SConstruct_path)s", line 5, in ? -""" % locals()) +""" + test.python_file_line(SConstruct_path, 5) + +test.run(arguments='-n', status=2, stderr=expect) test.must_not_exist('config.log') test.subdir('.sconf_temp') conftest_0_c = os.path.join(".sconf_temp", "conftest_0.c") +SConstruct_file_line = test.python_file_line(SConstruct_path, 6)[:-1] -test.run(arguments='-n', status=2, stderr=""" +expect = """ scons: *** Cannot update configure test "%(conftest_0_c)s" within a dry-run. -File "%(SConstruct_path)s", line 6, in ? -""" % locals()) +%(SConstruct_file_line)s +""" % locals() + +test.run(arguments='-n', status=2, stderr=expect) test.run() test.checkLogAndStdout( ["Checking for C library %s... " % lib, diff --git a/test/Configure/option--config.py b/test/Configure/option--config.py index 95a0d3b..807ddb5 100644 --- a/test/Configure/option--config.py +++ b/test/Configure/option--config.py @@ -60,11 +60,14 @@ test.write(['include', 'non_system_header1.h'], """ """) conftest_0_c = os.path.join(".sconf_temp", "conftest_0.c") +SConstruct_file_line = test.python_file_line(SConstruct_path, 6)[:-1] -test.run(arguments='--config=cache', status=2, stderr=""" +expect = """ scons: *** "%(conftest_0_c)s" is not yet built and cache is forced. -File "%(SConstruct_path)s", line 6, in ? -""" % locals()) +%(SConstruct_file_line)s +""" % locals() + +test.run(arguments='--config=cache', status=2, stderr=expect) test.run(arguments='--config=auto') test.checkLogAndStdout( ["Checking for C header file non_system_header1.h... ", |