diff options
Diffstat (limited to 'testsuite/driver/testlib.py')
-rw-r--r-- | testsuite/driver/testlib.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/testsuite/driver/testlib.py b/testsuite/driver/testlib.py index 8f76378531..431232c9dc 100644 --- a/testsuite/driver/testlib.py +++ b/testsuite/driver/testlib.py @@ -942,7 +942,12 @@ def do_test(name, way, func, args, files): t.unexpected_stat_failures.append(TestResult(directory, name, reason, way)) else: if_verbose(1, '*** unexpected failure for %s' % full_name) - t.unexpected_failures.append(TestResult(directory, name, reason, way)) + other = { + 'stdout': result.get('stdout'), + 'stderr': result.get('stderr') + } + result = TestResult(directory, name, reason, way, **other) + t.unexpected_failures.append(result) else: if opts.expect == 'missing-lib': t.missing_libs.append(TestResult(directory, name, 'missing-lib', way)) @@ -1078,7 +1083,7 @@ def do_compile(name, way, should_fail, top_mod, extra_mods, extra_hc_opts, **kwa whitespace_normaliser=getattr(getTestOpts(), "whitespace_normaliser", normalise_whitespace)): - return failBecause('stderr mismatch') + return failBecause('stderr mismatch', stderr=open(actual_stderr_file, 'rb').read()) # no problems found, this test passed return passed() |