Fixed test environment for escaped test output.

- test-lib uses 'read -r' to parse the test session input literally, without interpretation of backslashes.
- FIX: Use quoting to maintain original whitespace (tabs and multiple spaces) from the test session input (instead of condensing into a single space).
- Using Bash instead of POSIX shell for t1340-listescapes.sh, so that the interpretation of escape sequences is not dependent on the POSIX shell being used.
- Changed Makefile so that the shell selected by the shebang line is actually used when invoking tests, not the POSIX shell.
- Above changes obsolete the multiple escaping of the test session data; now, the test session can actually be pasted as-is into a test script, even when it contains backslashes. (I.e. works as expected now.)
This commit is contained in:
Ingo Karkat
2011-01-20 13:23:06 +01:00
parent a117b7cb3c
commit 2df5f9fee9
3 changed files with 9 additions and 13 deletions

View File

@@ -42,7 +42,7 @@ test-pre-clean:
aggregate-results: $(TESTS)
$(TESTS): test-pre-clean
-cd tests && sh $(notdir $@) $(TEST_OPTIONS)
-cd tests && ./$(notdir $@) $(TEST_OPTIONS)
test: aggregate-results
tests/aggregate-results.sh tests/test-results/t*-*