Fixed test failed handling