Skip to content

Commit 9df513c

Browse files
committed
Merge commit 'a40ce64825a231211f831dcd90ae626562f592dd'
* commit 'a40ce64825a231211f831dcd90ae626562f592dd': Squashed 'json/' changes from 4e6c78b4..689d2f28
2 parents 204c0c6 + a40ce64 commit 9df513c

File tree

3 files changed

+88
-84
lines changed

3 files changed

+88
-84
lines changed

json/tests/draft2019-09/anchor.json

Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
[
2+
{
3+
"description": "Location-independent identifier",
4+
"schema": {
5+
"allOf": [{
6+
"$ref": "#foo"
7+
}],
8+
"$defs": {
9+
"A": {
10+
"$anchor": "foo",
11+
"type": "integer"
12+
}
13+
}
14+
},
15+
"tests": [
16+
{
17+
"data": 1,
18+
"description": "match",
19+
"valid": true
20+
},
21+
{
22+
"data": "a",
23+
"description": "mismatch",
24+
"valid": false
25+
}
26+
]
27+
},
28+
{
29+
"description": "Location-independent identifier with absolute URI",
30+
"schema": {
31+
"allOf": [{
32+
"$ref": "http://localhost:1234/bar#foo"
33+
}],
34+
"$defs": {
35+
"A": {
36+
"$id": "http://localhost:1234/bar",
37+
"$anchor": "foo",
38+
"type": "integer"
39+
}
40+
}
41+
},
42+
"tests": [
43+
{
44+
"data": 1,
45+
"description": "match",
46+
"valid": true
47+
},
48+
{
49+
"data": "a",
50+
"description": "mismatch",
51+
"valid": false
52+
}
53+
]
54+
},
55+
{
56+
"description": "Location-independent identifier with base URI change in subschema",
57+
"schema": {
58+
"$id": "http://localhost:1234/root",
59+
"allOf": [{
60+
"$ref": "http://localhost:1234/nested.json#foo"
61+
}],
62+
"$defs": {
63+
"A": {
64+
"$id": "nested.json",
65+
"$defs": {
66+
"B": {
67+
"$anchor": "foo",
68+
"type": "integer"
69+
}
70+
}
71+
}
72+
}
73+
},
74+
"tests": [
75+
{
76+
"data": 1,
77+
"description": "match",
78+
"valid": true
79+
},
80+
{
81+
"data": "a",
82+
"description": "mismatch",
83+
"valid": false
84+
}
85+
]
86+
}
87+
]

json/tests/draft2019-09/ref.json

Lines changed: 0 additions & 84 deletions
Original file line numberDiff line numberDiff line change
@@ -355,89 +355,5 @@
355355
"valid": false
356356
}
357357
]
358-
},
359-
{
360-
"description": "Location-independent identifier",
361-
"schema": {
362-
"allOf": [{
363-
"$ref": "#foo"
364-
}],
365-
"$defs": {
366-
"A": {
367-
"$id": "#foo",
368-
"type": "integer"
369-
}
370-
}
371-
},
372-
"tests": [
373-
{
374-
"data": 1,
375-
"description": "match",
376-
"valid": true
377-
},
378-
{
379-
"data": "a",
380-
"description": "mismatch",
381-
"valid": false
382-
}
383-
]
384-
},
385-
{
386-
"description": "Location-independent identifier with absolute URI",
387-
"schema": {
388-
"allOf": [{
389-
"$ref": "http://localhost:1234/bar#foo"
390-
}],
391-
"$defs": {
392-
"A": {
393-
"$id": "http://localhost:1234/bar#foo",
394-
"type": "integer"
395-
}
396-
}
397-
},
398-
"tests": [
399-
{
400-
"data": 1,
401-
"description": "match",
402-
"valid": true
403-
},
404-
{
405-
"data": "a",
406-
"description": "mismatch",
407-
"valid": false
408-
}
409-
]
410-
},
411-
{
412-
"description": "Location-independent identifier with base URI change in subschema",
413-
"schema": {
414-
"$id": "http://localhost:1234/root",
415-
"allOf": [{
416-
"$ref": "http://localhost:1234/nested.json#foo"
417-
}],
418-
"$defs": {
419-
"A": {
420-
"$id": "nested.json",
421-
"$defs": {
422-
"B": {
423-
"$id": "#foo",
424-
"type": "integer"
425-
}
426-
}
427-
}
428-
}
429-
},
430-
"tests": [
431-
{
432-
"data": 1,
433-
"description": "match",
434-
"valid": true
435-
},
436-
{
437-
"data": "a",
438-
"description": "mismatch",
439-
"valid": false
440-
}
441-
]
442358
}
443359
]

json/tests/latest

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
draft2019-09

0 commit comments

Comments
 (0)