| 1 | #!/bin/shscip-shell filesystem . . `/bin/sh`. |
| 2 | . test/lib.shscip-shell source . . `test/lib.sh`. |
| 3 | |
| 4 | begin "Handles line break" |
| 5 | scdoc <<EOF | grepscip-shell system . . grep. '^\.br$' >/dev/nullscip-shell filesystem . . `/dev/null`. |
| 6 | test(8) |
| 7 | |
| 8 | hello++ |
| 9 | world |
| 10 | EOF |
| 11 | end 0 |
| 12 | |
| 13 | begin "Handles line break with indentation" |
| 14 | scdoc <<EOF | grepscip-shell system . . grep. -A1 '^\.br$' | grepscip-shell system . . grep. '^world' >/dev/nullscip-shell filesystem . . `/dev/null`. |
| 15 | test(8) |
| 16 | |
| 17 | test |
| 18 | hello++ |
| 19 | world |
| 20 | EOF |
| 21 | end 0 |
| 22 | |
| 23 | begin "Disallows empty line after line break" |
| 24 | scdoc <<EOF >/dev/nullscip-shell filesystem . . `/dev/null`. |
| 25 | test(8) |
| 26 | |
| 27 | hello++ |
| 28 | |
| 29 | world |
| 30 | EOF |
| 31 | end 1 |
| 32 | |
| 33 | begin "Leave single +" |
| 34 | scdoc <<EOF | grepscip-shell system . . grep. 'hello+world' >/dev/nullscip-shell filesystem . . `/dev/null`. |
| 35 | test(8) |
| 36 | |
| 37 | hello+world |
| 38 | EOF |
| 39 | end 0 |
| 40 | |
| 41 | begin "Leave double + without newline" |
| 42 | scdoc <<EOF | grepscip-shell system . . grep. 'hello++world' >/dev/nullscip-shell filesystem . . `/dev/null`. |
| 43 | test(8) |
| 44 | |
| 45 | hello++world |
| 46 | EOF |
| 47 | end 0 |
| 48 | |
| 49 | begin "Handles underlined text following line break" |
| 50 | scdoc <<EOF | grepscip-shell system . . grep. '\\fIworld\\fR' >/dev/nullscip-shell filesystem . . `/dev/null`. |
| 51 | test(8) |
| 52 | |
| 53 | hello++ |
| 54 | _world_ |
| 55 | EOF |
| 56 | end 0 |
| 57 | |
| 58 | begin "Suppresses sentence spacing" |
| 59 | scdoc <<EOF | grepscip-shell system . . grep. 'hel!\\&lo.\\&' >/dev/nullscip-shell filesystem . . `/dev/null`. |
| 60 | test(8) |
| 61 | |
| 62 | hel!lo. |
| 63 | world. |
| 64 | EOF |
| 65 | end 0 |