* [uitest] add exception config.

This commit is contained in:
liyang
2024-11-20 15:54:32 +08:00
committed by 曹延义
parent 4fc58a3d0b
commit 6de2f0835e
2 changed files with 3 additions and 2 deletions
+1
View File
@@ -43,6 +43,7 @@ $config->uitest->chrome->options[] = '--ignore-certificate-errors';
$config->uitest->chrome->options[] = '--test-type';
$config->uitest->chrome->options[] = '--start-maximized';
$config->uitest->setExceptionHandler = true;
$config->uitest->exitBrowserOnException = true;
$extConfigFiles = glob(dirname(__FILE__) . DS . 'ext' . DS . '*.php');
if($extConfigFiles) foreach($extConfigFiles as $extConfigFile) include $extConfigFile;
+2 -2
View File
@@ -154,13 +154,13 @@ class tester extends result
$this->cookieFile = '/tmp/cookie';
// 设置异常处理函数
set_exception_handler(array($this, 'exceptionHandler'));
if($this->config->uitest->setExceptionHandler) set_exception_handler(array($this, 'exceptionHandler'));
}
/**
* Exception handler.
*
* @param int $e
* @param object $e
* @access public
* @return void
*/