Changeset 2531 for zzuf


Ignore:
Timestamp:
Jul 16, 2008, 11:51:53 AM (12 years ago)
Author:
Sam Hocevar
Message:
  • testsuite.h: do not test for grep -a if the option is unknown.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • zzuf/trunk/test/testsuite.sh

    r2529 r2531  
    4444        ZZOPTS="-s $seed -r $r"
    4545        case $file in
    46           *text*) ZZOPTS="$ZZOPTS -P '\n'" ;;
     46          *text*) ZZOPTS="$ZZOPTS -P '\\n' -R '\\000'" ;;
    4747        esac
    4848        echo "*** file $file, ratio $r ***"
     
    7676            check "$ZZOPTS" "tail -n 9999 $file" "tail -n 9999"
    7777            check "$ZZOPTS" "tail -n +1 $file" "tail -n +1"
    78             check "$ZZOPTS" "grep -a '' $file" "grep -a ''"
     78            if grep -a '' /dev/null >/dev/null 2>&1; then
     79                check "$ZZOPTS" "grep -a '' $file" "grep -a ''"
     80            fi
    7981            check "$ZZOPTS" "sed -e n $file" "sed -e n"
    8082            #check "$ZZOPTS" "cut -b1- $file" "cut -b1-"
     
    8284            check "$ZZOPTS" "-i tail -n 9999 < $file" "|tail -n 9999"
    8385            check "$ZZOPTS" "-i tail -n +1 < $file" "|tail -n +1"
    84             check "$ZZOPTS" "-i grep -a '' < $file" "|grep -a ''"
     86            if grep -a '' /dev/null >/dev/null 2>&1; then
     87                check "$ZZOPTS" "-i grep -a '' < $file" "|grep -a ''"
     88            fi
    8589            check "$ZZOPTS" "-i sed -e n < $file" "|sed -e n"
    8690            #check "$ZZOPTS" "-i cut -b1- < $file" "|cut -b1-"
Note: See TracChangeset for help on using the changeset viewer.