summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/FormatTest.php15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/FormatTest.php b/tests/FormatTest.php
index 06f30a3..4d9dde0 100644
--- a/tests/FormatTest.php
+++ b/tests/FormatTest.php
@@ -43,6 +43,21 @@ class FormatTest extends MockeryTestCase
$this->assertEquals($expectedJson, $serializedMessage);
}
+ public function testJsonFails(): void
+ {
+ $message = new Message(
+ level: Level::Info,
+ trace: debug_backtrace()[0],
+ context: NAN,
+ );
+
+ $format = Format::JSON;
+ $serializedMessage = $format->serialize($message);
+ $expectedJson = '';
+
+ $this->assertEquals($expectedJson, $serializedMessage);
+ }
+
public function testIntelliJ(): void
{
$message = new Message(