123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127 |
- #! /bin/sh
- . test-init.sh
- . tap-setup.sh
- cat > all.test <<END
- 1..21
- ok? a question
- not ok? a question
- ok+plus
- not ok+plus
- ok-minus
- not ok-minus
- ok
- not ok
- ok${tab} ${tab}9
- ok ${tab}${tab} 10
- not ok${tab} ${tab}11
- not ok ${tab}${tab} 12
- ok
- ok${tab}
- ok?
- ok!
- not ok
- not ok${tab}
- not ok?
- not ok!
- ok~
- END
- run_make -O -e FAIL check
- count_test_results total=21 pass=6 fail=6 xfail=4 xpass=1 skip=4 error=0
- weirdchars=\''"$!&()[]<>;^?*/@%=,.:'
- cat > all.test <<END
- 1..6
- ok $weirdchars
- not ok $weirdchars
- ok $weirdchars # TODO
- not ok $weirdchars # TODO
- ok $weirdchars # SKIP
- Bail out! $weirdchars
- END
- run_make -O -e FAIL check
- count_test_results total=6 pass=1 fail=1 xfail=1 xpass=1 skip=1 error=1
- $FGREP "PASS: all.test 1 $weirdchars" stdout
- $FGREP "FAIL: all.test 2 $weirdchars" stdout
- $FGREP "XPASS: all.test 3 $weirdchars" stdout
- $FGREP "XFAIL: all.test 4 $weirdchars" stdout
- $FGREP "SKIP: all.test 5 $weirdchars" stdout
- $FGREP "ERROR: all.test - Bail out! $weirdchars" stdout
- #
- # Trailing backslashes does not confuse the parser.
- #
- bs='\'
- cat > all.test <<END
- 1..6
- ok $bs
- not ok $bs
- ok # TODO $bs
- not ok # TODO $bs
- ok # SKIP $bs
- Bail out! $bs
- END
- run_make -O -e FAIL check
- count_test_results total=6 pass=1 fail=1 xfail=1 xpass=1 skip=1 error=1
- grep '^PASS: all\.test 1 \\$' stdout
- grep '^FAIL: all\.test 2 \\$' stdout
- grep '^XPASS: all\.test 3 # TODO \\$' stdout
- grep '^XFAIL: all\.test 4 # TODO \\$' stdout
- grep '^SKIP: all\.test 5 # SKIP \\$' stdout
- grep '^ERROR: all\.test - Bail out! \\$' stdout
- :
|