automake-commit
[Top][All Lists]
Advanced

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

[Automake-commit] [SCM] GNU Automake branch, testsuite-work, updated. v1


From: Stefano Lattarini
Subject: [Automake-commit] [SCM] GNU Automake branch, testsuite-work, updated. v1.11-1424-g27a399a
Date: Wed, 28 Sep 2011 08:19:21 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Automake".

http://git.sv.gnu.org/gitweb/?p=automake.git;a=commitdiff;h=27a399a94c622996b6d2d72ef76e442f532c0be7

The branch, testsuite-work has been updated
       via  27a399a94c622996b6d2d72ef76e442f532c0be7 (commit)
      from  821be501ceee5c76da4fdcb05b91f32162475597 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 27a399a94c622996b6d2d72ef76e442f532c0be7
Author: Stefano Lattarini <address@hidden>
Date:   Wed Sep 28 10:15:24 2011 +0200

    tests: fix spurious failures in tests on TAP + signals
    
    * tests/tap-signal.tap: Write the dummy test scripts as perl
    scripts, not as shell scripts, to work around unportabilities
    in the handling of signals.  In fact, even with bash, the older
    script were unable to properly deliver a SIGQUIT to themselves
    consistently.

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog            |    9 +++++++++
 tests/tap-signal.tap |   25 +++++++++++++++++++------
 2 files changed, 28 insertions(+), 6 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 2178b72..607c5c5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2011-09-28  Stefano Lattarini  <address@hidden>
+
+       tests: fix spurious failures in tests on TAP + signals
+       * tests/tap-signal.tap: Write the dummy test scripts as perl
+       scripts, not as shell scripts, to work around unportabilities
+       in the handling of signals.  In fact, even with bash, the older
+       script were unable to properly deliver a SIGQUIT to themselves
+       consistently.
+
 2011-09-26  Stefano Lattarini  <address@hidden>
 
        tests: fix spurious failure in test on ACLOCAL_PATH precedences
diff --git a/tests/tap-signal.tap b/tests/tap-signal.tap
index e27962e..9a18586 100755
--- a/tests/tap-signal.tap
+++ b/tests/tap-signal.tap
@@ -22,7 +22,11 @@ am_parallel_tests=yes
 
 plan_ 10
 
-echo TESTS = > Makefile.am
+cat > Makefile.am << END
+TEST_LOG_COMPILER = $PERL -w
+## Will be updated later.
+TESTS =
+END
 
 all_signals='1 2 3 9 13 15'
 blocked_signals=''
@@ -32,12 +36,21 @@ for sig in $all_signals; do
     blocked_signals="$blocked_signals $sig"
     continue
   fi
+  # Write the dummy test scripts in perl, not as shell scripts, to work
+  # around unportabilities in the handling of signals (in fact, even
+  # with bash, the older script were unable to properly deliver a SIGQUIT
+  # to themselves consistently).  The shebang is dummy here, as we prefer
+  # to rely on the definition of TEST_LOG_COMPILER instead.
   unindent > signal-$sig.test <<END
-    #!/bin/sh
-    echo 1..1
-    echo ok 1
-    kill -$sig \$\$
-    echo "Bail out! \$0 not killed?"
+    #! perl
+    # We need autoflush to avoid losing output, which could cause spurious
+    # "no test plan seen" in the TAP driver.
+    BEGIN { $| = 1 }
+    use warnings FATAL => "all";
+    print "1..1\\n";
+    print "ok 1\\n";
+    kill $sig, \$\$;
+    print "Bail out! \$0 not killed?\\n";
 END
   echo TESTS += signal-$sig.test >> Makefile.am
 done


hooks/post-receive
-- 
GNU Automake



reply via email to

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