automake-patches
[Top][All Lists]
Advanced

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

[FYI] {test-protocols} coverage: keyword "SKIP" in TAP plan is case-inse


From: Stefano Lattarini
Subject: [FYI] {test-protocols} coverage: keyword "SKIP" in TAP plan is case-insensitive
Date: Sun, 21 Aug 2011 15:39:47 +0200

* tests/tap-planskip-case-insensitive.test: New test.
* tests/tap-planskip.test: Remove now-duplicated checks.
* tests/Makefile.am (tap_with_common_setup_tests): Update.
---
 ChangeLog                                |    7 ++++
 tests/Makefile.am                        |    1 +
 tests/Makefile.in                        |    1 +
 tests/tap-planskip-case-insensitive.test |   46 ++++++++++++++++++++++++++++++
 tests/tap-planskip.test                  |    4 +-
 5 files changed, 57 insertions(+), 2 deletions(-)
 create mode 100755 tests/tap-planskip-case-insensitive.test

diff --git a/ChangeLog b/ChangeLog
index 810cee0..70a255f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2011-08-21  Stefano Lattarini  <address@hidden>
 
+       coverage: keyword "SKIP" in TAP plan is case-insensitive
+       * tests/tap-planskip-case-insensitive.test: New test.
+       * tests/tap-planskip.test: Remove now-duplicated checks.
+       * tests/Makefile.am (tap_with_common_setup_tests): Update.
+
+2011-08-21  Stefano Lattarini  <address@hidden>
+
        coverage: ambiguous use of TAP "TODO"/"SKIP" directives
        * tests/tap-ambiguous-directive.test: New test.
        * tests/tap-todo-skip-together.test: Reference it in heading
diff --git a/tests/Makefile.am b/tests/Makefile.am
index cd6ed2c..1dbdcb2 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -1195,6 +1195,7 @@ tap-planskip-late.test \
 tap-planskip-and-logging.test \
 tap-planskip-unplanned.test \
 tap-planskip-unplanned-corner.test \
+tap-planskip-case-insensitive.test \
 tap-planskip-whitespace.test \
 tap-planskip-badexit.test \
 tap-planskip-bailout.test \
diff --git a/tests/Makefile.in b/tests/Makefile.in
index ed955ac..631bd8c 100644
--- a/tests/Makefile.in
+++ b/tests/Makefile.in
@@ -1436,6 +1436,7 @@ tap-planskip-late.test \
 tap-planskip-and-logging.test \
 tap-planskip-unplanned.test \
 tap-planskip-unplanned-corner.test \
+tap-planskip-case-insensitive.test \
 tap-planskip-whitespace.test \
 tap-planskip-badexit.test \
 tap-planskip-bailout.test \
diff --git a/tests/tap-planskip-case-insensitive.test 
b/tests/tap-planskip-case-insensitive.test
new file mode 100755
index 0000000..2ed2626
--- /dev/null
+++ b/tests/tap-planskip-case-insensitive.test
@@ -0,0 +1,46 @@
+#! /bin/sh
+# Copyright (C) 2011 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+# TAP support:
+#  - "SKIP" keyword in a TAP plan is case-insensitive
+
+parallel_tests=yes
+. ./defs || Exit 1
+
+. "$testsrcdir"/tap-setup.sh || fatal_ "sourcing tap-setup.sh"
+
+# These nested loops are clearer without indentation.
+
+i=0
+for c1 in s S; do
+for c2 in k K; do
+for c3 in i I; do
+for c4 in p P; do
+  i=`expr $i + 1`
+  case $i in ?) i=0$i; esac
+  echo "1..0 # $c1$c2$c3$c4 foobar" > $i.test
+done; done; done; done
+
+TESTS="`echo *.test`" $MAKE -e check >stdout || { cat stdout; Exit 1; }
+cat stdout
+
+count_test_results total=16 pass=0 fail=0 xpass=0 xfail=0 skip=16 error=0
+
+for tst in *.test; do
+  grep "^SKIP: $tst .* foobar$" stdout
+done
+
+:
diff --git a/tests/tap-planskip.test b/tests/tap-planskip.test
index 2852305..574819b 100755
--- a/tests/tap-planskip.test
+++ b/tests/tap-planskip.test
@@ -49,12 +49,12 @@ cat > wget.test <<END
 END
 
 cat > curl.test <<END
-1..0 # skip: Can't connect to gnu.org!
+1..0 # SKIP: Can't connect to gnu.org!
 # See also wget.test
 END
 
 cat > mu.test <<END
-1..0 # Skip $weirdchars
+1..0 # SKIP $weirdchars
 END
 
 env TESTS='foo.test bar.test baz.test wget.test curl.test mu.test' \
-- 
1.7.2.3




reply via email to

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