Skip to content

Commit cf78d97

Browse files
committed
Handle differences in $ref for the location-independent ref remote.
See #454 (comment)
1 parent c2b28e9 commit cf78d97

6 files changed

+26
-4
lines changed

remotes/locationIndependentIdentifier.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"$ref": "#foo"
55
},
66
"A": {
7-
"id": "#foo",
7+
"$anchor": "foo",
88
"type": "integer"
99
}
1010
}
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+
}
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+
}

tests/draft4/refRemote.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@
171171
{
172172
"description": "Location-independent identifier in remote ref",
173173
"schema": {
174-
"$ref": "http://localhost:1234/locationIndependentIdentifier.json#/definitions/refToInteger"
174+
"$ref": "http://localhost:1234/locationIndependentIdentifierDraft4.json#/definitions/refToInteger"
175175
},
176176
"tests": [
177177
{

tests/draft6/refRemote.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@
196196
{
197197
"description": "Location-independent identifier in remote ref",
198198
"schema": {
199-
"$ref": "http://localhost:1234/locationIndependentIdentifier.json#/definitions/refToInteger"
199+
"$ref": "http://localhost:1234/locationIndependentIdentifierPre2019.json#/definitions/refToInteger"
200200
},
201201
"tests": [
202202
{

tests/draft7/refRemote.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@
196196
{
197197
"description": "Location-independent identifier in remote ref",
198198
"schema": {
199-
"$ref": "http://localhost:1234/locationIndependentIdentifier.json#/definitions/refToInteger"
199+
"$ref": "http://localhost:1234/locationIndependentIdentifierPre2019.json#/definitions/refToInteger"
200200
},
201201
"tests": [
202202
{

0 commit comments

Comments
 (0)