autoconf-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Autotest: simplify logic to compute test group result.


From: Ralf Wildenhues
Subject: Autotest: simplify logic to compute test group result.
Date: Sun, 13 Jun 2010 08:54:20 +0200
User-agent: Mutt/1.5.20 (2010-04-22)

This small cleanup goes on top of the color test, but only because same
text area is edited; reversing that order is trivial of course.

The patch is easiest to verify if you take the old file, move down the
first case as far as possible, and the last one up as far as possible.
They meet in the middle.  :-)

OK?

Thanks,
Ralf

    Autotest: simplify logic to compute test group result.
    
    * lib/autotest/general.m4 (AT_INIT): Compactify result
    computation logic.

diff --git a/lib/autotest/general.m4 b/lib/autotest/general.m4
index 86c27ee..e163a87 100644
--- a/lib/autotest/general.m4
+++ b/lib/autotest/general.m4
@@ -1174,12 +1174,6 @@ _ATEOF
   $at_verbose AS_ECHO_N(["$at_group. $at_setup_line: "])
   AS_ECHO_N(["$at_group. $at_setup_line: "]) >> "$at_group_log"
   case $at_xfail:$at_status in
-    *:99)
-       at_msg='FAILED ('`cat "$at_check_line_file"`')'
-       at_res=fail
-       at_errexit=$at_errexit_p
-       at_color=$at_red
-       ;;
     yes:0)
        at_msg="UNEXPECTED PASS"
        at_res=xpass
@@ -1198,18 +1192,18 @@ _ATEOF
        at_errexit=false
        at_color=$at_blu
        ;;
+    no:* | *:99)
+       at_msg='FAILED ('`cat "$at_check_line_file"`')'
+       at_res=fail
+       at_errexit=$at_errexit_p
+       at_color=$at_red
+       ;;
     yes:*)
        at_msg='expected failure ('`cat "$at_check_line_file"`')'
        at_res=xfail
        at_errexit=false
        at_color=$at_lgn
        ;;
-    no:*)
-       at_msg='FAILED ('`cat "$at_check_line_file"`')'
-       at_res=fail
-       at_errexit=$at_errexit_p
-       at_color=$at_red
-       ;;
   esac
   echo "$at_res" > "$at_job_dir/$at_res"
   # In parallel mode, output the summary line only afterwards.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]