Skip to content

Commit efb3c89

Browse files
authored
Merge pull request #127 from iainbeeston/extra-items-tests
Added tests for items when data contains more or less types than the schema
2 parents 27692ac + 654cc26 commit efb3c89

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

tests/draft4/items.json

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,21 @@
4040
"description": "wrong types",
4141
"data": [ "foo", 1 ],
4242
"valid": false
43+
},
44+
{
45+
"description": "incomplete array of items",
46+
"data": [ 1 ],
47+
"valid": true
48+
},
49+
{
50+
"description": "array with additional items",
51+
"data": [ 1, "foo", true ],
52+
"valid": true
53+
},
54+
{
55+
"description": "empty array",
56+
"data": [ ],
57+
"valid": true
4358
}
4459
]
4560
}

0 commit comments

Comments
 (0)