mirror of
https://github.com/yiisoft/yii2.git
synced 2026-03-04 06:24:36 +01:00
30 lines
668 B
PHP
30 lines
668 B
PHP
<?php
|
|
/**
|
|
* @link http://www.yiiframework.com/
|
|
* @copyright Copyright (c) 2008 Yii Software LLC
|
|
* @license http://www.yiiframework.com/license/
|
|
*/
|
|
|
|
namespace yiiunit\framework\base;
|
|
|
|
use yii\base\ErrorException;
|
|
use yiiunit\TestCase;
|
|
|
|
/**
|
|
* @group base
|
|
*/
|
|
class ErrorExceptionTest extends TestCase
|
|
{
|
|
public function testXdebugTrace()
|
|
{
|
|
if (!function_exists('xdebug_get_function_stack')) {
|
|
$this->markTestSkipped('Xdebug are required.');
|
|
}
|
|
try {
|
|
throw new ErrorException();
|
|
} catch (ErrorException $e){
|
|
$this->assertEquals(__FUNCTION__, $e->getTrace()[0]['function']);
|
|
}
|
|
}
|
|
}
|