#!/bin/sh
. test/lib.sh

begin "Handles line break"
scdoc <<EOF | grep '^\.br$' >/dev/null
test(8)

hello++
world
EOF
end 0

begin "Disallows empty line after line break"
scdoc <<EOF >/dev/null
test(8)

hello++

world
EOF
end 1

begin "Leave single +"
scdoc <<EOF | grep 'hello+world' >/dev/null
test(8)

hello+world
EOF
end 0

begin "Leave double + without newline"
scdoc <<EOF | grep 'hello++world' >/dev/null
test(8)

hello++world
EOF
end 0

begin "Handles underlined text following line break"
scdoc <<EOF | grep '\\fIworld\\fR' >/dev/null
test(8)

hello++
_world_
EOF
end 0

begin "Suppresses sentence spacing"
scdoc <<EOF | grep 'hel!\\&lo.\\&' >/dev/null
test(8)

hel!lo.
world.
EOF
end 0
