Last change
on this file since 3933 was
2573,
checked in by Sam Hocevar, 13 years ago
|
- Factored the test suite to avoid excessive code duplication.
|
-
Property svn:executable set to
*
|
File size:
684 bytes
|
Line | |
---|
1 | #!/bin/sh |
---|
2 | |
---|
3 | . "$(dirname "$0")/functions.inc" |
---|
4 | |
---|
5 | PROGRAM="$DIR/bug-div0" |
---|
6 | if [ ! -f "$PROGRAM" ]; then |
---|
7 | echo "error: test/bug-div0 is missing" |
---|
8 | exit 1 |
---|
9 | fi |
---|
10 | |
---|
11 | start_test "zzuf division-by-zero test" |
---|
12 | |
---|
13 | new_test "bug-div0 < /file-00" |
---|
14 | if ! $PROGRAM < "$DIR/file-00"; then |
---|
15 | fail_test " unexpected exit status $?" |
---|
16 | else |
---|
17 | pass_test " OK" |
---|
18 | fi |
---|
19 | |
---|
20 | new_test "zzuf -qi -r0 bug-div0 < /file-00" |
---|
21 | if ! "$ZZUF" -r0 -qi "$PROGRAM" < "$DIR/file-00"; then |
---|
22 | fail_test " unexpected exit status $?" |
---|
23 | else |
---|
24 | pass_test " OK" |
---|
25 | fi |
---|
26 | |
---|
27 | new_test "zzuf -qi bug-div0 < file-00" |
---|
28 | if "$ZZUF" -qi "$PROGRAM" < "$DIR/file-00"; then |
---|
29 | fail_test " unexpected exit status $?" |
---|
30 | else |
---|
31 | pass_test " OK" |
---|
32 | fi |
---|
33 | |
---|
34 | stop_test |
---|
35 | |
---|
36 | exit 0 |
---|
37 | |
---|
Note: See
TracBrowser
for help on using the repository browser.