Skip to content

Commit

Permalink
Fixed #141 "Tests under Windows".
Browse files Browse the repository at this point in the history
Thanks to Abs62, who noted that under Windows (in MSYS) tests fail
because '2>"$outc.stderr"' dumps CRLF to file instead of LF
and proposed a fix:
    sed -i 's/\r//g' "$outc.stderr"
  • Loading branch information
skvadrik committed Jul 30, 2017
1 parent cb6d309 commit eb58cfe
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions re2c/run_tests.sh.in
Expand Up @@ -173,6 +173,8 @@ run_pack() {
&& cp "../../$x" "$outx"
# run re2c
$valgrind $wine ../../$re2c $switches "$outx" 2>"$outc.stderr" 1>&2
# on windows stdout and stderr contain CR LF, cut CR to match test results
sed -i 's/\r//g' "$outc.stderr"
# paste all files dropped by re2c into output file
rm "$outx" && find . -type f \
| lc_run sort \
Expand Down

0 comments on commit eb58cfe

Please sign in to comment.