mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
test: Fixed DebuggerTest
Some tests relied on output format settings in other tests.
This commit is contained in:
parent
d47407353b
commit
c82693b920
1 changed files with 2 additions and 0 deletions
|
@ -165,6 +165,7 @@ class DebuggerTest extends CakeTestCase {
|
||||||
$this->_restoreError = true;
|
$this->_restoreError = true;
|
||||||
|
|
||||||
ob_start();
|
ob_start();
|
||||||
|
Debugger::output('js');
|
||||||
$a = array();
|
$a = array();
|
||||||
$b = $a['<script>alert(1)</script>'];
|
$b = $a['<script>alert(1)</script>'];
|
||||||
$result = ob_get_clean();
|
$result = ob_get_clean();
|
||||||
|
@ -186,6 +187,7 @@ class DebuggerTest extends CakeTestCase {
|
||||||
'traceLine' => '{:reference} - <a href="txmt://open?url=file://{:file}' .
|
'traceLine' => '{:reference} - <a href="txmt://open?url=file://{:file}' .
|
||||||
'&line={:line}">{:path}</a>, line {:line}'
|
'&line={:line}">{:path}</a>, line {:line}'
|
||||||
));
|
));
|
||||||
|
Debugger::output('js');
|
||||||
$result = Debugger::trace();
|
$result = Debugger::trace();
|
||||||
$this->assertMatchesRegularExpression('/' . preg_quote('txmt://open?url=file://', '/') . '(\/|[A-Z]:\\\\)' . '/', $result);
|
$this->assertMatchesRegularExpression('/' . preg_quote('txmt://open?url=file://', '/') . '(\/|[A-Z]:\\\\)' . '/', $result);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue