public function testErrorHandling()
{
$backup = error_reporting();
error_reporting(E_ALL);
$test = new MockErrorHandlingTest();
$test->run();
$expected = '/Missing argument 1/';
$results = $test->results();
$this->assertPattern($expected, $results[0]['message']);
$expected = '/Unit::_arrayPermute()/';
$this->assertPattern($expected, $results[0]['message']);
error_reporting($backup);
}