mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 11:28:25 +00:00
Updating other debugger tests.
This commit is contained in:
parent
49f687b0c4
commit
986b7d3eaa
1 changed files with 15 additions and 4 deletions
|
@ -347,7 +347,7 @@ TEXT;
|
|||
Debugger::log('cool');
|
||||
$result = file_get_contents(LOGS . 'debug.log');
|
||||
$this->assertPattern('/DebuggerTest\:\:testLog/i', $result);
|
||||
$this->assertPattern('/"cool"/', $result);
|
||||
$this->assertPattern("/'cool'/", $result);
|
||||
|
||||
unlink(TMP . 'logs' . DS . 'debug.log');
|
||||
|
||||
|
@ -356,8 +356,8 @@ TEXT;
|
|||
$this->assertPattern('/DebuggerTest\:\:testLog/i', $result);
|
||||
$this->assertPattern('/\[main\]/', $result);
|
||||
$this->assertPattern('/array/', $result);
|
||||
$this->assertPattern('/"whatever",/', $result);
|
||||
$this->assertPattern('/"here"/', $result);
|
||||
$this->assertPattern("/'whatever',/", $result);
|
||||
$this->assertPattern("/'here'/", $result);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -381,7 +381,18 @@ TEXT;
|
|||
ob_start();
|
||||
Debugger::dump($var);
|
||||
$result = ob_get_clean();
|
||||
$expected = "<pre>array(\n\t'People' => array()\n)</pre>";
|
||||
$expected = <<<TEXT
|
||||
<pre>array(
|
||||
'People' => array(
|
||||
(int) 0 => array(
|
||||
),
|
||||
(int) 1 => array(
|
||||
)
|
||||
)
|
||||
)</pre>
|
||||
TEXT;
|
||||
$result = str_replace(array("\r\n", "\n"), "", $result);
|
||||
$expected = str_replace(array("\r\n", "\n"), "", $expected);
|
||||
$this->assertEquals($expected, $result);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue