Skip to content

Commit 41aebb9

Browse files
committed
Add test for assertJsonMatchesSchemaString
1 parent ac83dc2 commit 41aebb9

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tests/AssertTraitTest.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,14 @@ public function testAssertJsonSchemaFailMessage()
5656
self::assertInstanceOf('PHPUnit_Framework_ExpectationFailedException', $exception);
5757
}
5858

59+
public function testAssertJsonMatchesSchemaString()
60+
{
61+
$content = json_decode('{"foo":123}');
62+
$schema = file_get_contents(self::getSchema('test.schema.json'));
63+
64+
AssertTraitImpl::assertJsonMatchesSchemaString($schema, $content);
65+
}
66+
5967
/**
6068
* Tests assertJsonValueEquals().
6169
*

0 commit comments

Comments
 (0)