Fix grep exception + error test checker