3 # Test the `guile-snarf' tool.
5 # Strip the first line, like GNU `tail -n +2' does, but in a portable
6 # way (`tail' on Solaris 10 doesn't support `-n +2' for instance.)
18 # GNU cpp emits a comment on the first line, which shows what
19 # arguments it was passed. Strip this line.
20 echo "$1" | guile-snarf
- | strip_first_line |
tr -d ' \t\n'
26 if [ x
"$x" != x
"$2" ]; then
27 echo "Incorrect output: expected \"$2\", but got \"$x\""
32 snarf_test
"^^a^:^" "a;"
33 snarf_test
" ^ ^ b ^ : ^ " "b;"
34 snarf_test
"c\n^^d^:^\ne" "d;"
35 snarf_test
"f^^g^:^h" "g;"
36 snarf_test
"^^i^:^j^^k^:^" "i;k;"