Improve test failure logging