Enhanced Error Reporting in lime 1.0.9
With the release of symfony 1.3.5 and 1.4.5, the testing library lime was updated to version 1.0.9. Apart from smaller bug fixes, this version features improved error reporting for exceptions, warning and notice errors.
Before this update lime used to present many failing tests as "dubious". This status indicated that PHP was interrupted in the test, for example because an exception was thrown or because of a segmentation fault. Unfortunately, "dubious" doesn't help a lot to inform about the real problem.
lime now tries to catch exceptions thrown in your code. When you run your test suite, these exception messages are included in the output. Such tests are now marked clearly with the label "errors".
PHP Warnings and Notices
lime is now also able to catch PHP warning and notice errors. Before this update, such errors were silently ignored. Your tests were marked as successful even though there might have been a load of errors!
To fix this critical problem, we added the option "error_reporting" to the
lime_test. When you set this option to
true, these PHP errors are
caught and clearly highlighted in the test output.
$t = new lime_test(7, array('error_reporting' => true)); ...
They are also included in the output of the test suite.
For backwards compatibility reasons, the default value for this option remains
false. We highly recommend though to set it to
true in all of your test
scripts to prevent unnoticed errors.
Enhanced Error Reporting in lime 1.0.9 symfony.com/index.php/blog/enhanced-error-reporting-in-lime-1-0-9Tweet this
Become a certified developer! Exams are online and available in all countries.Register Now
Comments are closed.
To ensure that comments stay relevant, they are closed for old posts.