Skip to content

Commit c4ed16d

Browse files
committed
add draft 2019-09 -> draft 7 test
1 parent 3df4712 commit c4ed16d

File tree

2 files changed

+25
-0
lines changed

2 files changed

+25
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"$id": "http://localhost:1234/draft7/integer.json",
3+
"$schema": "http://json-schema.org/draft-07/schema#",
4+
"dependentRequired": {
5+
"foo": ["bar"]
6+
}
7+
}

tests/draft2019-09/optional/cross-draft.json

+18
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,23 @@
1919
"valid": true
2020
}
2121
]
22+
},
23+
{
24+
"description": "refs to historic drafts are processed as historic drafts",
25+
"schema": {
26+
"type": "object",
27+
"allOf": [
28+
{ "properties": { "foo": true } },
29+
{ "$ref": "http://localhost:1234/draft7/ignore-dependentRequired.json" }
30+
]
31+
},
32+
"tests": [
33+
{
34+
"description": "missing bar is valid",
35+
"$comment": "if the implementation is not processing the $ref as a draft 7 schema, this test will fail",
36+
"data": {"foo": "any value"},
37+
"valid": true
38+
}
39+
]
2240
}
2341
]

0 commit comments

Comments
 (0)