fix test fail detection