Skip to content

Commit 9ffc81e

Browse files
committed
Merge commit 'ba8f9ae3bb8a191c660231aab30a3cd4a67e7bcb'
* commit 'ba8f9ae3bb8a191c660231aab30a3cd4a67e7bcb': Squashed 'json/' changes from 817b724b7..57001d26b
2 parents 9d5edb4 + ba8f9ae commit 9ffc81e

14 files changed

+173
-5
lines changed

json/tests/draft2019-09/additionalItems.json

+33
Original file line numberDiff line numberDiff line change
@@ -93,5 +93,38 @@
9393
"valid": true
9494
}
9595
]
96+
},
97+
{
98+
"description": "additionalItems should not look in applicators, valid case",
99+
"schema": {
100+
"allOf": [
101+
{ "items": [ { "type": "integer" } ] }
102+
],
103+
"additionalItems": { "type": "boolean" }
104+
},
105+
"tests": [
106+
{
107+
"description": "items defined in allOf are not examined",
108+
"data": [ 1, null ],
109+
"valid": true
110+
}
111+
]
112+
},
113+
{
114+
"description": "additionalItems should not look in applicators, invalid case",
115+
"schema": {
116+
"allOf": [
117+
{ "items": [ { "type": "integer" }, { "type": "string" } ] }
118+
],
119+
"items": [ {"type": "integer" } ],
120+
"additionalItems": { "type": "boolean" }
121+
},
122+
"tests": [
123+
{
124+
"description": "items defined in allOf are not examined",
125+
"data": [ 1, "hello" ],
126+
"valid": false
127+
}
128+
]
96129
}
97130
]

json/tests/draft2019-09/additionalProperties.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@
124124
},
125125
"tests": [
126126
{
127-
"description": "properties defined in allOf are not allowed",
127+
"description": "properties defined in allOf are not examined",
128128
"data": {"foo": 1, "bar": true},
129129
"valid": false
130130
}

json/tests/draft2019-09/optional/format/ipv4.json

+5
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,11 @@
2727
"description": "an IP address as an integer",
2828
"data": "0x7f000001",
2929
"valid": false
30+
},
31+
{
32+
"description": "an IP address as an integer (decimal)",
33+
"data": "2130706433",
34+
"valid": false
3035
}
3136
]
3237
}

json/tests/draft3/additionalItems.json

+16
Original file line numberDiff line numberDiff line change
@@ -93,5 +93,21 @@
9393
"valid": true
9494
}
9595
]
96+
},
97+
{
98+
"description": "additionalItems should not look in applicators",
99+
"schema": {
100+
"extends": [
101+
{ "items": [ { "type": "integer" } ] }
102+
],
103+
"additionalItems": { "type": "boolean" }
104+
},
105+
"tests": [
106+
{
107+
"description": "items defined in extends are not examined",
108+
"data": [ 1, null ],
109+
"valid": true
110+
}
111+
]
96112
}
97113
]

json/tests/draft3/additionalProperties.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@
124124
},
125125
"tests": [
126126
{
127-
"description": "properties defined in extends are not allowed",
127+
"description": "properties defined in extends are not examined",
128128
"data": {"foo": 1, "bar": true},
129129
"valid": false
130130
}

json/tests/draft4/additionalItems.json

+33
Original file line numberDiff line numberDiff line change
@@ -93,5 +93,38 @@
9393
"valid": true
9494
}
9595
]
96+
},
97+
{
98+
"description": "additionalItems should not look in applicators, valid case",
99+
"schema": {
100+
"allOf": [
101+
{ "items": [ { "type": "integer" } ] }
102+
],
103+
"additionalItems": { "type": "boolean" }
104+
},
105+
"tests": [
106+
{
107+
"description": "items defined in allOf are not examined",
108+
"data": [ 1, null ],
109+
"valid": true
110+
}
111+
]
112+
},
113+
{
114+
"description": "additionalItems should not look in applicators, invalid case",
115+
"schema": {
116+
"allOf": [
117+
{ "items": [ { "type": "integer" }, { "type": "string" } ] }
118+
],
119+
"items": [ {"type": "integer" } ],
120+
"additionalItems": { "type": "boolean" }
121+
},
122+
"tests": [
123+
{
124+
"description": "items defined in allOf are not examined",
125+
"data": [ 1, "hello" ],
126+
"valid": false
127+
}
128+
]
96129
}
97130
]

json/tests/draft4/additionalProperties.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@
124124
},
125125
"tests": [
126126
{
127-
"description": "properties defined in allOf are not allowed",
127+
"description": "properties defined in allOf are not examined",
128128
"data": {"foo": 1, "bar": true},
129129
"valid": false
130130
}

json/tests/draft4/optional/format/ipv4.json

+5
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,11 @@
2727
"description": "an IP address as an integer",
2828
"data": "0x7f000001",
2929
"valid": false
30+
},
31+
{
32+
"description": "an IP address as an integer (decimal)",
33+
"data": "2130706433",
34+
"valid": false
3035
}
3136
]
3237
}

json/tests/draft6/additionalItems.json

+33
Original file line numberDiff line numberDiff line change
@@ -93,5 +93,38 @@
9393
"valid": true
9494
}
9595
]
96+
},
97+
{
98+
"description": "additionalItems should not look in applicators, valid case",
99+
"schema": {
100+
"allOf": [
101+
{ "items": [ { "type": "integer" } ] }
102+
],
103+
"additionalItems": { "type": "boolean" }
104+
},
105+
"tests": [
106+
{
107+
"description": "items defined in allOf are not examined",
108+
"data": [ 1, null ],
109+
"valid": true
110+
}
111+
]
112+
},
113+
{
114+
"description": "additionalItems should not look in applicators, invalid case",
115+
"schema": {
116+
"allOf": [
117+
{ "items": [ { "type": "integer" }, { "type": "string" } ] }
118+
],
119+
"items": [ {"type": "integer" } ],
120+
"additionalItems": { "type": "boolean" }
121+
},
122+
"tests": [
123+
{
124+
"description": "items defined in allOf are not examined",
125+
"data": [ 1, "hello" ],
126+
"valid": false
127+
}
128+
]
96129
}
97130
]

json/tests/draft6/additionalProperties.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@
124124
},
125125
"tests": [
126126
{
127-
"description": "properties defined in allOf are not allowed",
127+
"description": "properties defined in allOf are not examined",
128128
"data": {"foo": 1, "bar": true},
129129
"valid": false
130130
}

json/tests/draft6/optional/format/ipv4.json

+5
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,11 @@
2727
"description": "an IP address as an integer",
2828
"data": "0x7f000001",
2929
"valid": false
30+
},
31+
{
32+
"description": "an IP address as an integer (decimal)",
33+
"data": "2130706433",
34+
"valid": false
3035
}
3136
]
3237
}

json/tests/draft7/additionalItems.json

+33
Original file line numberDiff line numberDiff line change
@@ -93,5 +93,38 @@
9393
"valid": true
9494
}
9595
]
96+
},
97+
{
98+
"description": "additionalItems should not look in applicators, valid case",
99+
"schema": {
100+
"allOf": [
101+
{ "items": [ { "type": "integer" } ] }
102+
],
103+
"additionalItems": { "type": "boolean" }
104+
},
105+
"tests": [
106+
{
107+
"description": "items defined in allOf are not examined",
108+
"data": [ 1, null ],
109+
"valid": true
110+
}
111+
]
112+
},
113+
{
114+
"description": "additionalItems should not look in applicators, invalid case",
115+
"schema": {
116+
"allOf": [
117+
{ "items": [ { "type": "integer" }, { "type": "string" } ] }
118+
],
119+
"items": [ {"type": "integer" } ],
120+
"additionalItems": { "type": "boolean" }
121+
},
122+
"tests": [
123+
{
124+
"description": "items defined in allOf are not examined",
125+
"data": [ 1, "hello" ],
126+
"valid": false
127+
}
128+
]
96129
}
97130
]

json/tests/draft7/additionalProperties.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@
124124
},
125125
"tests": [
126126
{
127-
"description": "properties defined in allOf are not allowed",
127+
"description": "properties defined in allOf are not examined",
128128
"data": {"foo": 1, "bar": true},
129129
"valid": false
130130
}

json/tests/draft7/optional/format/ipv4.json

+5
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,11 @@
2727
"description": "an IP address as an integer",
2828
"data": "0x7f000001",
2929
"valid": false
30+
},
31+
{
32+
"description": "an IP address as an integer (decimal)",
33+
"data": "2130706433",
34+
"valid": false
3035
}
3136
]
3237
}

0 commit comments

Comments
 (0)