diff options
author | hexcoder- <heiko@hexco.de> | 2021-01-02 23:17:30 +0100 |
---|---|---|
committer | hexcoder- <heiko@hexco.de> | 2021-01-02 23:17:30 +0100 |
commit | 3c88de565a9074f202aeef92416472d17b82d697 (patch) | |
tree | 3bd0367fee59e6b383475bf4b1abe60311d859e5 /test | |
parent | 8bcb17b11f3690a06323542ef9b2e885d5f28dd7 (diff) | |
download | AFLplusplus-3c88de565a9074f202aeef92416472d17b82d697.tar.gz |
afl-cmin tests: allow leading whitespace in `wc -l` output
Diffstat (limited to 'test')
-rwxr-xr-x | test/test-basic.sh | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/test-basic.sh b/test/test-basic.sh index ffd16dd1..8296b6cc 100755 --- a/test/test-basic.sh +++ b/test/test-basic.sh @@ -210,7 +210,7 @@ test "$SYS" = "i686" -o "$SYS" = "x86_64" -o "$SYS" = "amd64" -o "$SYS" = "i86pc CNT=`ls in2/* 2>/dev/null | wc -l` case "$CNT" in *2) $ECHO "$GREEN[+] afl-cmin correctly minimized the number of testcases" ;; - 1) { + \ *1|1) { # allow leading whitecase for portability test -s in2/* && $ECHO "$YELLOW[?] afl-cmin did minimize to one testcase. This can be a bug or due compiler optimization." test -s in2/* || { $ECHO "$RED[!] afl-cmin did not correctly minimize the number of testcases ($CNT)" @@ -229,8 +229,8 @@ test "$SYS" = "i686" -o "$SYS" = "x86_64" -o "$SYS" = "amd64" -o "$SYS" = "i86pc CNT=`ls in2/* 2>/dev/null | wc -l` case "$CNT" in *2) $ECHO "$GREEN[+] afl-cmin.bash correctly minimized the number of testcases" ;; - 1) { - test -s in2/* && $ECHO "$YELLOW[?] afl-cmin.bash did minimize to one testcase. This can be a bug or due compiler optimization." + \ *1|1) { # allow leading whitecase for portability + test -s in2/* && $ECHO "$YELLOW[?] afl-cmin.bash did minimize to one testcase. This can be a bug or due compiler optimization." test -s in2/* || { $ECHO "$RED[!] afl-cmin.bash did not correctly minimize the number of testcases ($CNT)" CODE=1 |