@ 201216.1 · fetching

160413.1.1 · 1f2d79ebeec6849f6e151fc125b41539ef39e844

Use printf in place of echo in tests

The behaviour of echo is inconsistent between implementations, in particular regarding whether it expands escapes like `\n`. Use printf consistently in test scripts to avoid test failures from inconsistent echo behaviour.

Fixes #866.

reading declarations

Changes to tests/exitcodes.t. All files

tests/exitcodes.t

@@ -1,8 +1,8 @@ Setup:    $ . $TESTDIR/setup.sh-  $ echo foo > ./exitcodes_test.txt-  $ echo bar >> ./exitcodes_test.txt+  $ printf 'foo\n' > ./exitcodes_test.txt+  $ printf 'bar\n' >> ./exitcodes_test.txt  Normal matching: