Ensure that the current directory is not changed up if a test fails, and fix messages for the assertion failures.