Ch 729

Looks like simpletest indicates a message and passes a specific div to be styled as an error in order to achieve this when running tests.
https://github.com/boombatower/drupal/blob/master/modules/simpletest/simpletest.module#L194

Not saying you need to go this far at all, but it's all I see that can indicate an error during batch processing itself.