diff options
-rwxr-xr-x | src/test/test_parseconf.sh | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/src/test/test_parseconf.sh b/src/test/test_parseconf.sh index f298072c3e..962d43dd77 100755 --- a/src/test/test_parseconf.sh +++ b/src/test/test_parseconf.sh @@ -311,20 +311,23 @@ for dir in "${EXAMPLEDIR}"/*; do if ! cmp "${DATA_DIR}/output.${testname}" \ "${DATA_DIR}/output_2.${testname}"; then - echo "FAIL: $EXPECTED did not match on round-trip." >&2 + echo "FAIL: $EXPECTED did not match on round-trip:" >&2 + diff -u "${DATA_DIR}/output.${testname}" \ + "${DATA_DIR}/output_2.${testname}" >&2 \ + || true FINAL_EXIT=$EXITCODE fi else FAILED_CONFIG="yes" - echo "FAIL" >&2 if test "$(wc -c < "${DATA_DIR}/output.${testname}")" = 0; then + echo "FAIL: $EXPECTED: Tor said:" >&2 # There was no output -- probably we failed. "${TOR_BINARY}" -f "./torrc" \ --defaults-torrc "${DEFAULTS}" \ --verify-config \ ${CMDLINE} || true fi - echo "FAIL: $EXPECTED did not match." >&2 + echo "FAIL: $EXPECTED did not match:" >&2 diff -u "$EXPECTED" "${DATA_DIR}/output.${testname}" >&2 \ || true FINAL_EXIT=$EXITCODE @@ -346,8 +349,8 @@ for dir in "${EXAMPLEDIR}"/*; do : else FAILED_LOG="yes" - echo "FAIL" >&2 - echo "Expected $EXPECTED_LOG: ${expect_log}" >&2 + echo "FAIL: Expected $EXPECTED_LOG:" >&2 + echo "${expect_log}" >&2 echo "Tor said:" >&2 cat "${DATA_DIR}/output_log.${testname}" >&2 FINAL_EXIT=$EXITCODE @@ -378,8 +381,8 @@ for dir in "${EXAMPLEDIR}"/*; do if grep "${expect_err}" "${DATA_DIR}/output.${testname}" >/dev/null; then echo "OK" else - echo "FAIL" >&2 - echo "Expected $ERROR: ${expect_err}" >&2 + echo "FAIL: Expected $ERROR: " >&2 + echo "${expect_err}" >&2 echo "Tor said:" >&2 cat "${DATA_DIR}/output.${testname}" >&2 FINAL_EXIT=$EXITCODE |