From 7bc282a561dca0d9e0a910cc31cd2280020c082a Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Mon, 19 Sep 2011 16:08:06 -0700 Subject: [PATCH] Revert "Check for the correct exit code on cfail tests. Closes #938" This reverts commit c42401ebbc82d319c3003088db47f825d65fb9f7. --- src/test/compiletest/runtest.rs | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/test/compiletest/runtest.rs b/src/test/compiletest/runtest.rs index de188f3927e3..46b74e799f4f 100644 --- a/src/test/compiletest/runtest.rs +++ b/src/test/compiletest/runtest.rs @@ -41,7 +41,6 @@ fn run_cfail_test(cx: cx, props: test_props, testfile: str) { fatal_procres("compile-fail test compiled successfully!", procres); } - check_correct_failure_status(procres); check_error_patterns(props, testfile, procres); } @@ -58,19 +57,16 @@ fn run_rfail_test(cx: cx, props: test_props, testfile: str) { fatal_procres("run-fail test isn't valgrind-clean!", procres); } - check_correct_failure_status(procres); - check_error_patterns(props, testfile, procres); -} - -fn check_correct_failure_status(procres: procres) { // The value the rust runtime returns on failure const rust_err: int = 101; if procres.status != rust_err { fatal_procres( - #fmt("failure produced the wrong error code: %d", + #fmt("run-fail test produced the wrong error code: %d", procres.status), procres); } + + check_error_patterns(props, testfile, procres); } fn run_rpass_test(cx: cx, props: test_props, testfile: str) {