grep-commit
[Top][All Lists]
Advanced

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

grep branch, master, updated. v2.25-99-ge27724d


From: Jim Meyering
Subject: grep branch, master, updated. v2.25-99-ge27724d
Date: Sun, 25 Sep 2016 02:22:36 +0000 (UTC)

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 "grep".

The branch, master has been updated
       via  e27724dafd3066c52697f1b4d6f6066772a872f2 (commit)
      from  7c4c69400c6ab456f1fdea4d0960c5a49cb040eb (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 -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit/grep.git/commit/?id=e27724dafd3066c52697f1b4d6f6066772a872f2


commit e27724dafd3066c52697f1b4d6f6066772a872f2
Author: Jim Meyering <address@hidden>
Date:   Sat Sep 24 19:13:33 2016 -0700

    tests/fmbtest: avoid false-failure due to reliance on MB-correct sed
    
    * tests/fmbtest: Several of these tests would mistakenly fail due to
    postprocessing with a combination of sed and locale support that failed
    to handle some multibyte characters in the cs_CZ.UTF-8 locale.  Instead
    of relying on sed's multibyte support or anything locale-related to
    perform this simple filtering, just use this: tr -cs '0-9' '[ *]'
    Also, rather than exporting LC_ALL, just set it for each command.
    Reported by Nelson H. F. Beebe.
    https://bugs.gnu.org/24534

diff --git a/tests/fmbtest b/tests/fmbtest
index 6f60f03..14fb9d3 100755
--- a/tests/fmbtest
+++ b/tests/fmbtest
@@ -52,25 +52,22 @@ EOF
 
 for mode in F G E; do
 
-test1=$(echo $(LC_ALL=$cz; export LC_ALL
-               grep -${mode} -f cspatfile csinput |
-                 sed 's/[^0123456789]/ /g'))
+test1=$(echo $(LC_ALL=$cz grep -${mode} -f cspatfile csinput |
+               tr -cs '0-9' '[ *]'))
 if test "$test1" != "11 12 13 14 15 16 17 18"; then
   echo "Test #1 ${mode} failed: $test1"
   failures=1
 fi
 
-test2=$(echo $(LC_ALL=$cz; export LC_ALL
-               grep -${mode}i -f cspatfile csinput |
-                 sed 's/[^0123456789]/ /g'))
+test2=$(echo $(LC_ALL=$cz grep -${mode}i -f cspatfile csinput |
+               tr -cs '0-9' '[ *]'))
 if test "$test2" != "01 02 07 08 10 11 12 13 14 15 16 17 18 19 20"; then
   echo "Test #2 ${mode} failed: $test2"
   failures=1
 fi
 
-test3=$(echo $(LC_ALL=$cz; export LC_ALL
-               grep -${mode}i -e 'ČÍšE' -e 'Čas' csinput |
-                 sed 's/[^0123456789]/ /g'))
+test3=$(echo $(LC_ALL=$cz grep -${mode}i -e 'ČÍšE' -e 'Čas' csinput |
+               tr -cs '0-9' '[ *]'))
 if test "$test3" != "01 02 07 08 10 11 12 13 14 15 16 17 18 19 20"; then
   echo "Test #3 ${mode} failed: $test3"
   failures=1
@@ -117,9 +114,8 @@ done
 
 for mode in G E; do
 
-test8=$(echo $(LC_ALL=$cz; export LC_ALL
-               grep -${mode}i -e 'Č.šE' -e 'Č[a-f]s' csinput |
-                 sed 's/[^0123456789]/ /g'))
+test8=$(echo $(LC_ALL=$cz grep -${mode}i -e 'Č.šE' -e 'Č[a-f]s' csinput |
+               tr -cs '0-9' '[ *]'))
 if test "$test8" != "01 02 07 08 10 11 12 13 14 15 16 17 18 19 20"; then
   echo "Test #8 ${mode} failed: $test8"
   failures=1

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

Summary of changes:
 tests/fmbtest |   20 ++++++++------------
 1 file changed, 8 insertions(+), 12 deletions(-)


hooks/post-receive
-- 
grep



reply via email to

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