mirror of
https://github.com/Seldaek/monolog.git
synced 2025-08-10 23:24:02 +02:00
Add support for PSR-3 levels to all public APIs accepting levels, fixes #421
This commit is contained in:
@@ -13,7 +13,6 @@ namespace Monolog\Handler;
|
||||
|
||||
use Monolog\TestCase;
|
||||
use Monolog\Logger;
|
||||
use Psr\Log\LogLevel;
|
||||
|
||||
class NewRelicHandlerTest extends TestCase
|
||||
{
|
||||
@@ -85,7 +84,7 @@ class NewRelicHandlerTest extends TestCase
|
||||
|
||||
public function testTheAppNameCanBeInjectedFromtheConstructor()
|
||||
{
|
||||
$handler = new StubNewRelicHandler(LogLevel::ALERT, false, 'myAppName');
|
||||
$handler = new StubNewRelicHandler(Logger::DEBUG, false, 'myAppName');
|
||||
$handler->handle($this->getRecord(Logger::ERROR, 'log message'));
|
||||
|
||||
$this->assertEquals('myAppName', self::$appname);
|
||||
@@ -93,7 +92,7 @@ class NewRelicHandlerTest extends TestCase
|
||||
|
||||
public function testTheAppNameCanBeOverriddenFromEachLog()
|
||||
{
|
||||
$handler = new StubNewRelicHandler(LogLevel::ALERT, false, 'myAppName');
|
||||
$handler = new StubNewRelicHandler(Logger::DEBUG, false, 'myAppName');
|
||||
$handler->handle($this->getRecord(Logger::ERROR, 'log message', array('appname' => 'logAppName')));
|
||||
|
||||
$this->assertEquals('logAppName', self::$appname);
|
||||
|
Reference in New Issue
Block a user