From e505dbd36f3c8c43a645a176babefabfd0a72eeb Mon Sep 17 00:00:00 2001 From: Greg Steuck Date: Sat, 8 Jan 2022 21:01:13 -0800 Subject: Remove from error the parenthesized amount of memory requested Diagnostics for outofmem test on OpenBSD includes the amount of memory that it failed to allocate. This seems like an irrelevant detail that could change over time and isn't required for determining if test passed. Typical elided text is '(requested 2148532224 bytes)' --- testsuite/tests/rts/all.T | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'testsuite/tests/rts') diff --git a/testsuite/tests/rts/all.T b/testsuite/tests/rts/all.T index a62585c6f4..7b31d159f3 100644 --- a/testsuite/tests/rts/all.T +++ b/testsuite/tests/rts/all.T @@ -82,6 +82,9 @@ test('divbyzero', when(opsys('mingw32'), omit_ways(prof_ways))], compile_and_run, ['-with-rtsopts="--generate-stack-traces=no"']) +def remove_parenthesis(s): + return re.sub(r'\s+\([^)]*\)', '', s) + test('outofmem', [ when(opsys('darwin'), skip), # this is believed to cause other processes to die # that happen concurrently while the outofmem test @@ -89,7 +92,8 @@ test('outofmem', [ when(opsys('darwin'), skip), # windows, to prevent absolute exhaustion of memory # and subsequent termination (and failure) of unrelated # tests. - when(opsys('mingw32'), skip) ], + when(opsys('mingw32'), skip), + normalise_errmsg_fun(remove_parenthesis)], makefile_test, ['outofmem']) test('outofmem2', normal, makefile_test, ['outofmem2']) -- cgit v1.2.1