Skip to content

Commit a66d23d

Browse files
move draft-specific files to the dedicated dir for its draft
..otherwise, draft-specific test suites won't know to skip adding the file
1 parent 8ef1550 commit a66d23d

16 files changed

+99
-17
lines changed
File renamed without changes.
File renamed without changes.

remotes/draft4/subSchemas.json

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"definitions": {
3+
"integer": {
4+
"type": "integer"
5+
},
6+
"refToInteger": {
7+
"$ref": "#/definitions/integer"
8+
}
9+
}
10+
}

remotes/draft6/name.json

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"definitions": {
3+
"orNull": {
4+
"anyOf": [
5+
{
6+
"type": "null"
7+
},
8+
{
9+
"$ref": "#"
10+
}
11+
]
12+
}
13+
},
14+
"type": "string"
15+
}

remotes/ref-and-definitions.json renamed to remotes/draft6/ref-and-definitions.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"$id": "http://localhost:1234/ref-and-definitions.json",
2+
"$id": "http://localhost:1234/draft6/ref-and-definitions.json",
33
"definitions": {
44
"inner": {
55
"properties": {

remotes/draft6/subSchemas.json

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"definitions": {
3+
"integer": {
4+
"type": "integer"
5+
},
6+
"refToInteger": {
7+
"$ref": "#/definitions/integer"
8+
}
9+
}
10+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"definitions": {
3+
"refToInteger": {
4+
"$ref": "#foo"
5+
},
6+
"A": {
7+
"$id": "#foo",
8+
"type": "integer"
9+
}
10+
}
11+
}

remotes/draft7/name.json

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"definitions": {
3+
"orNull": {
4+
"anyOf": [
5+
{
6+
"type": "null"
7+
},
8+
{
9+
"$ref": "#"
10+
}
11+
]
12+
}
13+
},
14+
"type": "string"
15+
}
+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"$id": "http://localhost:1234/draft7/ref-and-definitions.json",
3+
"definitions": {
4+
"inner": {
5+
"properties": {
6+
"bar": { "type": "string" }
7+
}
8+
}
9+
},
10+
"allOf": [ { "$ref": "#/definitions/inner" } ]
11+
}

remotes/draft7/subSchemas.json

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"definitions": {
3+
"integer": {
4+
"type": "integer"
5+
},
6+
"refToInteger": {
7+
"$ref": "#/definitions/integer"
8+
}
9+
}
10+
}

tests/draft3/refRemote.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
},
1818
{
1919
"description": "fragment within remote ref",
20-
"schema": {"$ref": "http://localhost:1234/subSchemas.json#/definitions/integer"},
20+
"schema": {"$ref": "http://localhost:1234/draft3/subSchemas.json#/definitions/integer"},
2121
"tests": [
2222
{
2323
"description": "remote fragment valid",
@@ -34,7 +34,7 @@
3434
{
3535
"description": "ref within remote ref",
3636
"schema": {
37-
"$ref": "http://localhost:1234/subSchemas.json#/definitions/refToInteger"
37+
"$ref": "http://localhost:1234/draft3/subSchemas.json#/definitions/refToInteger"
3838
},
3939
"tests": [
4040
{

tests/draft4/refRemote.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
},
1818
{
1919
"description": "fragment within remote ref",
20-
"schema": {"$ref": "http://localhost:1234/subSchemas.json#/definitions/integer"},
20+
"schema": {"$ref": "http://localhost:1234/draft4/subSchemas.json#/definitions/integer"},
2121
"tests": [
2222
{
2323
"description": "remote fragment valid",
@@ -34,7 +34,7 @@
3434
{
3535
"description": "ref within remote ref",
3636
"schema": {
37-
"$ref": "http://localhost:1234/subSchemas.json#/definitions/refToInteger"
37+
"$ref": "http://localhost:1234/draft4/subSchemas.json#/definitions/refToInteger"
3838
},
3939
"tests": [
4040
{
@@ -139,7 +139,7 @@
139139
"id": "http://localhost:1234/object",
140140
"type": "object",
141141
"properties": {
142-
"name": {"$ref": "name.json#/definitions/orNull"}
142+
"name": {"$ref": "draft4/name.json#/definitions/orNull"}
143143
}
144144
},
145145
"tests": [
@@ -171,7 +171,7 @@
171171
{
172172
"description": "Location-independent identifier in remote ref",
173173
"schema": {
174-
"$ref": "http://localhost:1234/locationIndependentIdentifierDraft4.json#/definitions/refToInteger"
174+
"$ref": "http://localhost:1234/draft4/locationIndependentIdentifier.json#/definitions/refToInteger"
175175
},
176176
"tests": [
177177
{

tests/draft6/refRemote.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
},
1818
{
1919
"description": "fragment within remote ref",
20-
"schema": {"$ref": "http://localhost:1234/subSchemas.json#/definitions/integer"},
20+
"schema": {"$ref": "http://localhost:1234/draft6/subSchemas.json#/definitions/integer"},
2121
"tests": [
2222
{
2323
"description": "remote fragment valid",
@@ -34,7 +34,7 @@
3434
{
3535
"description": "ref within remote ref",
3636
"schema": {
37-
"$ref": "http://localhost:1234/subSchemas.json#/definitions/refToInteger"
37+
"$ref": "http://localhost:1234/draft6/subSchemas.json#/definitions/refToInteger"
3838
},
3939
"tests": [
4040
{
@@ -139,7 +139,7 @@
139139
"$id": "http://localhost:1234/object",
140140
"type": "object",
141141
"properties": {
142-
"name": {"$ref": "name.json#/definitions/orNull"}
142+
"name": {"$ref": "draft6/name.json#/definitions/orNull"}
143143
}
144144
},
145145
"tests": [
@@ -173,7 +173,7 @@
173173
"schema": {
174174
"$id": "http://localhost:1234/schema-remote-ref-ref-defs1.json",
175175
"allOf": [
176-
{ "$ref": "ref-and-definitions.json" }
176+
{ "$ref": "draft6/ref-and-definitions.json" }
177177
]
178178
},
179179
"tests": [
@@ -196,7 +196,7 @@
196196
{
197197
"description": "Location-independent identifier in remote ref",
198198
"schema": {
199-
"$ref": "http://localhost:1234/locationIndependentIdentifierPre2019.json#/definitions/refToInteger"
199+
"$ref": "http://localhost:1234/draft6/locationIndependentIdentifier.json#/definitions/refToInteger"
200200
},
201201
"tests": [
202202
{

tests/draft7/refRemote.json

+5-5
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
},
1818
{
1919
"description": "fragment within remote ref",
20-
"schema": {"$ref": "http://localhost:1234/subSchemas.json#/definitions/integer"},
20+
"schema": {"$ref": "http://localhost:1234/draft7/subSchemas.json#/definitions/integer"},
2121
"tests": [
2222
{
2323
"description": "remote fragment valid",
@@ -34,7 +34,7 @@
3434
{
3535
"description": "ref within remote ref",
3636
"schema": {
37-
"$ref": "http://localhost:1234/subSchemas.json#/definitions/refToInteger"
37+
"$ref": "http://localhost:1234/draft7/subSchemas.json#/definitions/refToInteger"
3838
},
3939
"tests": [
4040
{
@@ -139,7 +139,7 @@
139139
"$id": "http://localhost:1234/object",
140140
"type": "object",
141141
"properties": {
142-
"name": {"$ref": "name.json#/definitions/orNull"}
142+
"name": {"$ref": "draft7/name.json#/definitions/orNull"}
143143
}
144144
},
145145
"tests": [
@@ -173,7 +173,7 @@
173173
"schema": {
174174
"$id": "http://localhost:1234/schema-remote-ref-ref-defs1.json",
175175
"allOf": [
176-
{ "$ref": "ref-and-definitions.json" }
176+
{ "$ref": "draft7/ref-and-definitions.json" }
177177
]
178178
},
179179
"tests": [
@@ -196,7 +196,7 @@
196196
{
197197
"description": "Location-independent identifier in remote ref",
198198
"schema": {
199-
"$ref": "http://localhost:1234/locationIndependentIdentifierPre2019.json#/definitions/refToInteger"
199+
"$ref": "http://localhost:1234/draft7/locationIndependentIdentifier.json#/definitions/refToInteger"
200200
},
201201
"tests": [
202202
{

0 commit comments

Comments
 (0)