1
0
mirror of https://github.com/Seldaek/monolog.git synced 2025-07-31 10:20:14 +02:00
This commit is contained in:
Sergey Chizhik
2014-12-05 14:36:37 +02:00
parent 7902b8c396
commit 21c54ac660
2 changed files with 3 additions and 3 deletions

View File

@@ -99,7 +99,7 @@ class LineFormatter extends NormalizerFormatter
} while ($previous = $previous->getPrevious()); } while ($previous = $previous->getPrevious());
} }
return '[object] ('.get_class($e).'(code:'.$e->getCode().'): '.$e->getMessage().' at '.$e->getFile().':'.$e->getLine().$previousText.')'; return '[object] ('.get_class($e).'(code: '.$e->getCode().'): '.$e->getMessage().' at '.$e->getFile().':'.$e->getLine().$previousText.')';
} }
protected function convertToString($data) protected function convertToString($data)

View File

@@ -120,7 +120,7 @@ class LineFormatterTest extends \PHPUnit_Framework_TestCase
$path = str_replace('\\/', '/', json_encode(__FILE__)); $path = str_replace('\\/', '/', json_encode(__FILE__));
$this->assertEquals('['.date('Y-m-d').'] core.CRITICAL: foobar {"exception":"[object] (RuntimeException(code:0): Foo at '.substr($path, 1, -1).':'.(__LINE__-8).')"} []'."\n", $message); $this->assertEquals('['.date('Y-m-d').'] core.CRITICAL: foobar {"exception":"[object] (RuntimeException(code: 0): Foo at '.substr($path, 1, -1).':'.(__LINE__-8).')"} []'."\n", $message);
} }
public function testDefFormatWithPreviousException() public function testDefFormatWithPreviousException()
@@ -138,7 +138,7 @@ class LineFormatterTest extends \PHPUnit_Framework_TestCase
$path = str_replace('\\/', '/', json_encode(__FILE__)); $path = str_replace('\\/', '/', json_encode(__FILE__));
$this->assertEquals('['.date('Y-m-d').'] core.CRITICAL: foobar {"exception":"[object] (RuntimeException(code:0): Foo at '.substr($path, 1, -1).':'.(__LINE__-8).', LogicException(code: 0): Wut? at '.substr($path, 1, -1).':'.(__LINE__-12).')"} []'."\n", $message); $this->assertEquals('['.date('Y-m-d').'] core.CRITICAL: foobar {"exception":"[object] (RuntimeException(code: 0): Foo at '.substr($path, 1, -1).':'.(__LINE__-8).', LogicException(code: 0): Wut? at '.substr($path, 1, -1).':'.(__LINE__-12).')"} []'."\n", $message);
} }
public function testBatchFormat() public function testBatchFormat()