Skip to content

Commit 1c6c965

Browse files
committed
Merge commit 'c9b74362198d21cea59794c414f0877452ab9fa7'
* commit 'c9b74362198d21cea59794c414f0877452ab9fa7': Squashed 'json/' changes from 329efe59c..9263b5250
2 parents 7ea7365 + c9b7436 commit 1c6c965

File tree

7 files changed

+140
-0
lines changed

7 files changed

+140
-0
lines changed

json/tests/draft-next/uniqueItems.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
"data": [1, 1],
1414
"valid": false
1515
},
16+
{
17+
"description": "non-unique array of more than two integers is invalid",
18+
"data": [1, 2, 1],
19+
"valid": false
20+
},
1621
{
1722
"description": "numbers are unique if mathematically unequal",
1823
"data": [1.0, 1.00, 1],
@@ -28,6 +33,16 @@
2833
"data": [1, true],
2934
"valid": true
3035
},
36+
{
37+
"description": "unique array of strings is valid",
38+
"data": ["foo", "bar", "baz"],
39+
"valid": true
40+
},
41+
{
42+
"description": "non-unique array of strings is invalid",
43+
"data": ["foo", "bar", "foo"],
44+
"valid": false
45+
},
3146
{
3247
"description": "unique array of objects is valid",
3348
"data": [{"foo": "bar"}, {"foo": "baz"}],
@@ -64,6 +79,11 @@
6479
"data": [["foo"], ["foo"]],
6580
"valid": false
6681
},
82+
{
83+
"description": "non-unique array of more than two arrays is invalid",
84+
"data": [["foo"], ["bar"], ["foo"]],
85+
"valid": false
86+
},
6787
{
6888
"description": "1 and true are unique",
6989
"data": [1, true],

json/tests/draft2019-09/uniqueItems.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
"data": [1, 1],
1414
"valid": false
1515
},
16+
{
17+
"description": "non-unique array of more than two integers is invalid",
18+
"data": [1, 2, 1],
19+
"valid": false
20+
},
1621
{
1722
"description": "numbers are unique if mathematically unequal",
1823
"data": [1.0, 1.00, 1],
@@ -28,6 +33,16 @@
2833
"data": [1, true],
2934
"valid": true
3035
},
36+
{
37+
"description": "unique array of strings is valid",
38+
"data": ["foo", "bar", "baz"],
39+
"valid": true
40+
},
41+
{
42+
"description": "non-unique array of strings is invalid",
43+
"data": ["foo", "bar", "foo"],
44+
"valid": false
45+
},
3146
{
3247
"description": "unique array of objects is valid",
3348
"data": [{"foo": "bar"}, {"foo": "baz"}],
@@ -64,6 +79,11 @@
6479
"data": [["foo"], ["foo"]],
6580
"valid": false
6681
},
82+
{
83+
"description": "non-unique array of more than two arrays is invalid",
84+
"data": [["foo"], ["bar"], ["foo"]],
85+
"valid": false
86+
},
6787
{
6888
"description": "1 and true are unique",
6989
"data": [1, true],

json/tests/draft2020-12/uniqueItems.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
"data": [1, 1],
1414
"valid": false
1515
},
16+
{
17+
"description": "non-unique array of more than two integers is invalid",
18+
"data": [1, 2, 1],
19+
"valid": false
20+
},
1621
{
1722
"description": "numbers are unique if mathematically unequal",
1823
"data": [1.0, 1.00, 1],
@@ -28,6 +33,16 @@
2833
"data": [1, true],
2934
"valid": true
3035
},
36+
{
37+
"description": "unique array of strings is valid",
38+
"data": ["foo", "bar", "baz"],
39+
"valid": true
40+
},
41+
{
42+
"description": "non-unique array of strings is invalid",
43+
"data": ["foo", "bar", "foo"],
44+
"valid": false
45+
},
3146
{
3247
"description": "unique array of objects is valid",
3348
"data": [{"foo": "bar"}, {"foo": "baz"}],
@@ -64,6 +79,11 @@
6479
"data": [["foo"], ["foo"]],
6580
"valid": false
6681
},
82+
{
83+
"description": "non-unique array of more than two arrays is invalid",
84+
"data": [["foo"], ["bar"], ["foo"]],
85+
"valid": false
86+
},
6787
{
6888
"description": "1 and true are unique",
6989
"data": [1, true],

json/tests/draft3/uniqueItems.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,26 @@
1313
"data": [1, 1],
1414
"valid": false
1515
},
16+
{
17+
"description": "non-unique array of more than two integers is invalid",
18+
"data": [1, 2, 1],
19+
"valid": false
20+
},
1621
{
1722
"description": "numbers are unique if mathematically unequal",
1823
"data": [1.0, 1.00, 1],
1924
"valid": false
2025
},
26+
{
27+
"description": "unique array of strings is valid",
28+
"data": ["foo", "bar", "baz"],
29+
"valid": true
30+
},
31+
{
32+
"description": "non-unique array of strings is invalid",
33+
"data": ["foo", "bar", "foo"],
34+
"valid": false
35+
},
2136
{
2237
"description": "unique array of objects is valid",
2338
"data": [{"foo": "bar"}, {"foo": "baz"}],
@@ -54,6 +69,11 @@
5469
"data": [["foo"], ["foo"]],
5570
"valid": false
5671
},
72+
{
73+
"description": "non-unique array of more than two arrays is invalid",
74+
"data": [["foo"], ["bar"], ["foo"]],
75+
"valid": false
76+
},
5777
{
5878
"description": "1 and true are unique",
5979
"data": [1, true],

json/tests/draft4/uniqueItems.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
"data": [1, 1],
1414
"valid": false
1515
},
16+
{
17+
"description": "non-unique array of more than two integers is invalid",
18+
"data": [1, 2, 1],
19+
"valid": false
20+
},
1621
{
1722
"description": "numbers are unique if mathematically unequal",
1823
"data": [1.0, 1.00, 1],
@@ -28,6 +33,16 @@
2833
"data": [1, true],
2934
"valid": true
3035
},
36+
{
37+
"description": "unique array of strings is valid",
38+
"data": ["foo", "bar", "baz"],
39+
"valid": true
40+
},
41+
{
42+
"description": "non-unique array of strings is invalid",
43+
"data": ["foo", "bar", "foo"],
44+
"valid": false
45+
},
3146
{
3247
"description": "unique array of objects is valid",
3348
"data": [{"foo": "bar"}, {"foo": "baz"}],
@@ -64,6 +79,11 @@
6479
"data": [["foo"], ["foo"]],
6580
"valid": false
6681
},
82+
{
83+
"description": "non-unique array of more than two arrays is invalid",
84+
"data": [["foo"], ["bar"], ["foo"]],
85+
"valid": false
86+
},
6787
{
6888
"description": "1 and true are unique",
6989
"data": [1, true],

json/tests/draft6/uniqueItems.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
"data": [1, 1],
1414
"valid": false
1515
},
16+
{
17+
"description": "non-unique array of more than two integers is invalid",
18+
"data": [1, 2, 1],
19+
"valid": false
20+
},
1621
{
1722
"description": "numbers are unique if mathematically unequal",
1823
"data": [1.0, 1.00, 1],
@@ -28,6 +33,16 @@
2833
"data": [1, true],
2934
"valid": true
3035
},
36+
{
37+
"description": "unique array of strings is valid",
38+
"data": ["foo", "bar", "baz"],
39+
"valid": true
40+
},
41+
{
42+
"description": "non-unique array of strings is invalid",
43+
"data": ["foo", "bar", "foo"],
44+
"valid": false
45+
},
3146
{
3247
"description": "unique array of objects is valid",
3348
"data": [{"foo": "bar"}, {"foo": "baz"}],
@@ -64,6 +79,11 @@
6479
"data": [["foo"], ["foo"]],
6580
"valid": false
6681
},
82+
{
83+
"description": "non-unique array of more than two arrays is invalid",
84+
"data": [["foo"], ["bar"], ["foo"]],
85+
"valid": false
86+
},
6787
{
6888
"description": "1 and true are unique",
6989
"data": [1, true],

json/tests/draft7/uniqueItems.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
"data": [1, 1],
1414
"valid": false
1515
},
16+
{
17+
"description": "non-unique array of more than two integers is invalid",
18+
"data": [1, 2, 1],
19+
"valid": false
20+
},
1621
{
1722
"description": "numbers are unique if mathematically unequal",
1823
"data": [1.0, 1.00, 1],
@@ -28,6 +33,16 @@
2833
"data": [1, true],
2934
"valid": true
3035
},
36+
{
37+
"description": "unique array of strings is valid",
38+
"data": ["foo", "bar", "baz"],
39+
"valid": true
40+
},
41+
{
42+
"description": "non-unique array of strings is invalid",
43+
"data": ["foo", "bar", "foo"],
44+
"valid": false
45+
},
3146
{
3247
"description": "unique array of objects is valid",
3348
"data": [{"foo": "bar"}, {"foo": "baz"}],
@@ -64,6 +79,11 @@
6479
"data": [["foo"], ["foo"]],
6580
"valid": false
6681
},
82+
{
83+
"description": "non-unique array of more than two arrays is invalid",
84+
"data": [["foo"], ["bar"], ["foo"]],
85+
"valid": false
86+
},
6787
{
6888
"description": "1 and true are unique",
6989
"data": [1, true],

0 commit comments

Comments
 (0)