disable error handler while running phpunit

remotes/origin/stable5
Thomas Mueller 11 years ago
parent 86f4126d2c
commit 77369d8164

@ -402,9 +402,11 @@ class OC {
self::initPaths();
register_shutdown_function(array('OC_Log', 'onShutdown'));
set_error_handler(array('OC_Log', 'onError'));
set_exception_handler(array('OC_Log', 'onException'));
if (!defined('PHPUNIT_RUN')) {
register_shutdown_function(array('OC_Log', 'onShutdown'));
set_error_handler(array('OC_Log', 'onError'));
set_exception_handler(array('OC_Log', 'onException'));
}
// set debug mode if an xdebug session is active
if (!defined('DEBUG') || !DEBUG) {

@ -2,6 +2,9 @@
global $RUNTIME_NOAPPS;
$RUNTIME_NOAPPS = true;
define('PHPUNIT_RUN', 1);
require_once __DIR__.'/../lib/base.php';
if(!class_exists('PHPUnit_Framework_TestCase')) {

Loading…
Cancel
Save