Skip to content

Commit 8a9cd12

Browse files
Tests all the things!
1 parent 853eb09 commit 8a9cd12

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

tests/Constraints/CoerciveTest.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,13 @@ public function dataCoerceCases()
165165
'integer', 'boolean', true, true
166166
);
167167

168+
// #51 check boolean coercion with "const"
169+
$tests[] = array(
170+
'{"properties":{"propertyOne":{"type":"boolean","const":false}}}',
171+
'{"propertyOne":"false"}',
172+
'string', 'boolean', false, true
173+
);
174+
168175
foreach ($types as $toType => $testCases) {
169176
foreach ($testCases as $testCase) {
170177
$tests[] = array(

0 commit comments

Comments
 (0)