work around BSD sed not interpreting \r in s/$/\r/

* src/kripketest/bad_parsing.test, src/tgbatest/neverclaimread.test,
src/tgbatest/readsave.test, src/tgbatest/hoaparse.test: Use Perl for the
unix2dos conversion.
This commit is contained in:
Alexandre Duret-Lutz 2014-12-05 10:25:33 +01:00
parent a0d9268fda
commit 88da1ad84d
4 changed files with 6 additions and 11 deletions

View file

@ -68,8 +68,7 @@ cat output | grep -v + > res
diff expected res diff expected res
# The diagnostic should be the same with DOS return lines # The diagnostic should be the same with DOS return lines
sed 's/$/\r/' input > input.dos perl -pi -e 's/$/\r/' input
mv input.dos input
run 1 ../parse_print input 2> output run 1 ../parse_print input 2> output
cat output | grep -v + > res cat output | grep -v + > res
diff expected res diff expected res

View file

@ -453,8 +453,7 @@ input:8.1-16.12: aborted input automaton
EOF EOF
# DOS-style new lines should have the same output. # DOS-style new lines should have the same output.
sed 's/$/\r/g' input > input.dos perl -pi -e 's/$/\r/' input
mv input.dos input
../../bin/autfilt --hoa input 2>stderr && exit 1 ../../bin/autfilt --hoa input 2>stderr && exit 1
cat stderr cat stderr
diff stderr input.exp diff stderr input.exp
@ -669,8 +668,7 @@ EOF
diff expected input.out diff expected input.out
# DOS-style new lines should have the same output. # DOS-style new lines should have the same output.
sed 's/$/\r/g' input > input.dos perl -pe -e 's/$/\r/' input
mv input.dos input
../../bin/autfilt --hoa input 2>stderr && exit 1 ../../bin/autfilt --hoa input 2>stderr && exit 1
cat stderr cat stderr
diff stderr input.exp diff stderr input.exp

View file

@ -293,8 +293,7 @@ grep input: stderr > stderrfilt
diff stderrfilt expected-err diff stderrfilt expected-err
# DOS-style new lines should have the same output. # DOS-style new lines should have the same output.
sed 's/$/\r/g' input > input.dos perl -pi -e 's/$/\r/' input
mv input.dos input
run 2 ../ltl2tgba -ks -XN input > stdout 2>stderr run 2 ../ltl2tgba -ks -XN input > stdout 2>stderr
cat stderr cat stderr
grep input: stderr > stderrfilt grep input: stderr > stderrfilt

View file

@ -3,7 +3,7 @@
# Copyright (C) 2009, 2010, 2012, 2014 Laboratoire de Recherche et # Copyright (C) 2009, 2010, 2012, 2014 Laboratoire de Recherche et
# Développement de l'Epita (LRDE). # Développement de l'Epita (LRDE).
# Copyright (C) 2003, 2004 Laboratoire d'Informatique de Paris 6 (LIP6), # Copyright (C) 2003, 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
# département Systèmes Répartis Coopératifs (SRC), Université Pierre # département Systèmes Répartis Coopératifs (SRC), Université Pierre
# et Marie Curie. # et Marie Curie.
# #
# This file is part of Spot, a model checking library. # This file is part of Spot, a model checking library.
@ -123,8 +123,7 @@ EOF
diff stderrfilt expected diff stderrfilt expected
# The diagnostic should be the same with DOS input # The diagnostic should be the same with DOS input
sed 's/$/\r/' input > input.dos perl -pi -e 's/$/\r/' input
mv input.dos input
run 2 ../ltl2tgba -b -X input > stdout 2>stderr run 2 ../ltl2tgba -b -X input > stdout 2>stderr
cat stderr cat stderr
grep input: stderr > stderrfilt grep input: stderr > stderrfilt