1
0
mirror of https://github.com/Seldaek/monolog.git synced 2025-08-11 23:54:04 +02:00

Added the support of a logging context

This commit is contained in:
Christophe Coevoet
2011-06-01 00:10:38 +02:00
parent a8d4fc4a34
commit c1675c59d8
13 changed files with 74 additions and 60 deletions

View File

@@ -31,8 +31,8 @@ class FirePHPHandlerTest extends TestCase
'X-Wf-Protocol-1' => 'http://meta.wildfirehq.org/Protocol/JsonStream/0.2',
'X-Wf-1-Structure-1' => 'http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1',
'X-Wf-1-Plugin-1' => 'http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.3',
'X-Wf-1-1-1-1' => '50|[{"Type":"LOG","File":"","Line":""},"test: test "]|',
'X-Wf-1-1-1-2' => '51|[{"Type":"WARN","File":"","Line":""},"test: test "]|',
'X-Wf-1-1-1-1' => '55|[{"Type":"LOG","File":"","Line":""},"test: test [] []"]|',
'X-Wf-1-1-1-2' => '56|[{"Type":"WARN","File":"","Line":""},"test: test [] []"]|',
);
$this->assertEquals($expected, $handler->getHeaders());
@@ -52,13 +52,13 @@ class FirePHPHandlerTest extends TestCase
'X-Wf-Protocol-1' => 'http://meta.wildfirehq.org/Protocol/JsonStream/0.2',
'X-Wf-1-Structure-1' => 'http://meta.firephp.org/Wildfire/Structure/FirePHP/FirebugConsole/0.1',
'X-Wf-1-Plugin-1' => 'http://meta.firephp.org/Wildfire/Plugin/FirePHP/Library-FirePHPCore/0.3',
'X-Wf-1-1-1-1' => '50|[{"Type":"LOG","File":"","Line":""},"test: test "]|',
'X-Wf-1-1-1-2' => '51|[{"Type":"WARN","File":"","Line":""},"test: test "]|',
'X-Wf-1-1-1-1' => '55|[{"Type":"LOG","File":"","Line":""},"test: test [] []"]|',
'X-Wf-1-1-1-2' => '56|[{"Type":"WARN","File":"","Line":""},"test: test [] []"]|',
);
$expected2 = array(
'X-Wf-1-1-1-3' => '50|[{"Type":"LOG","File":"","Line":""},"test: test "]|',
'X-Wf-1-1-1-4' => '51|[{"Type":"WARN","File":"","Line":""},"test: test "]|',
'X-Wf-1-1-1-3' => '55|[{"Type":"LOG","File":"","Line":""},"test: test [] []"]|',
'X-Wf-1-1-1-4' => '56|[{"Type":"WARN","File":"","Line":""},"test: test [] []"]|',
);
$this->assertEquals($expected, $handler->getHeaders());