]> git.ipfire.org Git - thirdparty/autoconf.git/commitdiff
* tests/atgeneral.m4: Add basic support for test ranges (e.g. 7-34) as
authorTim Van Holder <tim.van.holder@pandora.be>
Thu, 20 Sep 2001 15:08:21 +0000 (15:08 +0000)
committerTim Van Holder <tim.van.holder@pandora.be>
Thu, 20 Sep 2001 15:08:21 +0000 (15:08 +0000)
  arguments.  Fixed a typo.

ChangeLog
tests/atgeneral.m4

index 83f41360a7ee419c503017c4ce979926c74931f4..f591877842058a3e2259da062d36ebcc6d896bd6 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2001-09-20  Tim Van Holder  <tim.van.holder@pandora.be>
+
+       * tests/atgeneral.m4: Add basic support for test ranges (e.g. 7-34) as
+       arguments.  Fixed a typo.
+
 2001-09-20  Tim Van Holder  <tim.van.holder@pandora.be>
 
        * man/Makefile.am (.x.1): Use @PATH_SEPARATOR@, not ':' to set up
index 77b32e95c4abbf02cda151ce49835f72b339cd37..1376fb0555c220b4f283750abb0f83f3ff7ce8ec 100644 (file)
@@ -146,6 +146,33 @@ while test $[#] -gt 0; do
     [[0-9] | [0-9][0-9] | [0-9][0-9][0-9] | [0-9][0-9][0-9][0-9]])
         at_tests="$at_tests$[1] ";;
 
+    # Ranges
+    [[0-9]- | [0-9][0-9]- | [0-9][0-9][0-9]- | [0-9][0-9][0-9][0-9]-])
+        at_range_start=`echo $[1] |tr -d '-'`
+        at_range=`echo " $at_tests_all " | \
+          sed -e 's,^.* '$at_range_start' ,'$at_range_start' ,'`
+        at_tests="$at_tests$at_range ";;
+
+    [-[0-9] | -[0-9][0-9] | -[0-9][0-9][0-9] | -[0-9][0-9][0-9][0-9]])
+        at_range_end=`echo $[1] |tr -d '-'`
+        at_range=`echo " $at_tests_all " | \
+          sed -e 's, '$at_range_end' .*$, '$at_range_end','`
+        at_tests="$at_tests$at_range ";;
+
+    [[0-9]-[0-9] | [0-9]-[0-9][0-9] | [0-9]-[0-9][0-9][0-9]] | \
+    [[0-9]-[0-9][0-9][0-9][0-9] | [0-9][0-9]-[0-9][0-9]] | \
+    [[0-9][0-9]-[0-9][0-9][0-9] | [0-9][0-9]-[0-9][0-9][0-9][0-9]] | \
+    [[0-9][0-9][0-9]-[0-9][0-9][0-9]] | \
+    [[0-9][0-9][0-9]-[0-9][0-9][0-9][0-9]] | \
+    [[0-9][0-9][0-9][0-9]-[0-9][0-9][0-9][0-9]] )
+        at_range_start=`echo $[1] |sed 's,-.*,,'`
+        at_range_end=`echo $[1] |sed 's,.*-,,'`
+       # Maybe test to make sure start <= end
+        at_range=`echo " $at_tests_all " | \
+          sed -e 's,^.* '$at_range_start' ,'$at_range_start' ,' \
+              -e 's, '$at_range_end' .*$, '$at_range_end','`
+        at_tests="$at_tests$at_range ";;
+
      *) echo "$as_me: invalid option: $[1]" >&2
         echo "Try \`$[0] --help' for more information." >&2
         exit 1 ;;
@@ -299,7 +326,7 @@ elif test $at_debug = false; then
   echo ', done'
   echo
   echo 'You may investigate any problem if you feel able to do so, in which'
-  echo 'case the testsuite provide a good starting point.'
+  echo 'case the test suite provides a good starting point.'
   echo
   echo 'Now, failed tests will be executed again, verbosely, and logged'
   echo 'in the file '$[0]'.log.'