diff --git a/docs/src/code/writing-tests.adoc b/docs/src/code/writing-tests.adoc index c50061f1a4a..02e73c5465f 100644 --- a/docs/src/code/writing-tests.adoc +++ b/docs/src/code/writing-tests.adoc @@ -68,9 +68,6 @@ checkresult:: The exit code of this program controls the result of the test. If both `expected` and `checkresult` exist, only `checkresult` is consulted to validate the test output. - xfail:: - If this file exist, a test failure is expected and does not cause runtests to return an exit code signaling an error. - skip:: If this file exist, the test is skipped and not executed at all. diff --git a/scripts/runtests.in b/scripts/runtests.in index 0b2fc95901a..76ccab8ce3d 100755 --- a/scripts/runtests.in +++ b/scripts/runtests.in @@ -45,7 +45,6 @@ export RUNTESTS NUM=0 FAIL=0; FAIL_NAMES="" -XFAIL=0 SHMERR=0 SKIP=0 VERBOSE=0 @@ -286,7 +285,7 @@ run_tests () { fi fi if [ "$exitcode" -ne 0 ]; then - echo "*** $testdir: XFAIL: $reason" + echo "*** $testdir: FAIL: $reason" if test $PRINT = 1; then echo "************** result:" tail -500 "$testdir/result" | sed 's/^/ /' @@ -294,27 +293,15 @@ run_tests () { tail -500 "$testdir/stderr" | sed 's/^/ /' echo "**************" fi - if [ -f "$testdir/xfail" ]; then - XFAIL=$((XFAIL + 1)) - if [ $NOCLEAN -eq 0 ]; then - rm -f "$testdir/stderr" "$testdir/result" \ - "$testdir"/*.var "$testdir"/*.var.bak - fi - else - FAIL=$((FAIL + 1)) - FAIL_NAMES="$FAIL_NAMES"$'\n'"$testdir" - fi + FAIL=$((FAIL + 1)) + FAIL_NAMES="$FAIL_NAMES"$'\n'"$testdir" if test $STOP = 1; then break fi else - if [ -f "$testdir/xfail" ]; then - echo "*** $testdir: XPASS: Passed, but was expected to fail" - else - if [ $NOCLEAN -eq 0 ]; then - rm -f "$testdir/stderr" "$testdir/result" \ - "$testdir"/*.var "$testdir"/*.var.bak - fi + if [ $NOCLEAN -eq 0 ]; then + rm -f "$testdir/stderr" "$testdir/result" \ + "$testdir"/*.var "$testdir"/*.var.bak fi fi @@ -327,8 +314,8 @@ run_tests () { fi done < "$TMPDIR/alltests" - SUCC=$((NUM-FAIL-XFAIL)) - echo "Runtest: $NUM tests run, $SUCC successful, $FAIL failed + $XFAIL expected, $SKIP skipped, $SHMERR shmem errors" + SUCC=$((NUM-FAIL)) + echo "Runtest: $NUM tests run, $SUCC successful, $FAIL failed, $SKIP skipped, $SHMERR shmem errors" if [ "$FAIL" -ne 0 ]; then echo "Failed: $FAIL_NAMES" exit 1; diff --git a/tests/interp/m98m99/12-M99-endless-main-program/xfail b/tests/interp/m98m99/12-M99-endless-main-program/xfail deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/tests/overrun/README b/tests/overrun/README index 3c44e21e20b..414a47e7a19 100644 --- a/tests/overrun/README +++ b/tests/overrun/README @@ -1,2 +1,2 @@ -This test makes sure that the "overrun" detection works. It is an XFAIL -because the testing infrastructure will believe it is a failure. +This test makes sure that the "overrun" detection works. The inner runtests +run is expected to fail, so test.sh negates its exit code. diff --git a/tests/overrun/checkresult b/tests/overrun/checkresult index b64faf30722..414899285da 100755 --- a/tests/overrun/checkresult +++ b/tests/overrun/checkresult @@ -2,4 +2,4 @@ set -e grep -q "overrun detected in sampler" "$1" grep -q "10 overruns detected, giving up" "$1" -grep -q "1 tests run, 0 successful, 1 failed . 0 expected" "$1" +grep -q "1 tests run, 0 successful, 1 failed," "$1"