[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Keep testsuite files on unexpected pass.
From: |
Ralf Wildenhues |
Subject: |
Re: [PATCH] Keep testsuite files on unexpected pass. |
Date: |
Sat, 14 Aug 2010 08:55:34 +0200 |
User-agent: |
Mutt/1.5.20 (2010-04-22) |
* Peter Rosin wrote on Tue, Aug 10, 2010 at 11:08:03PM CEST:
> Subject: [PATCH] Keep testsuite files on unexpected pass.
>
> * lib/autotest/general.m4 (AT_INIT) <at_fn_group_postprocess>:
> Don't cleanup the group directory when a test unexpectedly passes.
> * tests/autotest.at (Cleanup): Check that an unexpected pass leaves
> the test group directory intact.
For what it's worth, this patch looks good to me. The "Cleanup" test
group might be a bit more complex than needed, but that's not new with
your patch.
Also I just noticed that --errexit is broken wrt. XPASS tests, but
that's not new with your patch either. The following seems to fix
it but I don't have testsuite exposure yet. One thing to note for
the latter is that the "test ... and inhibited subsequent tests."
notice is not necessarily true, in that the testsuite does run
subsequent tests after an XPASS.
Cheers,
Ralf
diff --git a/lib/autotest/general.m4 b/lib/autotest/general.m4
index 7b1a300..ba8c6e6 100644
--- a/lib/autotest/general.m4
+++ b/lib/autotest/general.m4
@@ -1244,6 +1244,9 @@ _ATEOF
# or the success was unexpected.
if $at_debug_p || test $at_res = xpass; then
at_fn_create_debugging_script
+ if test $at_res = xpass && $at_errexit; then
+ echo stop > "$at_stop_file"
+ fi
else
if test -d "$at_group_dir"; then
find "$at_group_dir" -type d ! -perm -700 -exec chmod u+rwx \{\} \;