File tree Expand file tree Collapse file tree 1 file changed +55
-0
lines changed Expand file tree Collapse file tree 1 file changed +55
-0
lines changed Original file line number Diff line number Diff line change 57
57
"valid" : true
58
58
}
59
59
]
60
+ },
61
+ {
62
+ "description" : " items with boolean schema (true)" ,
63
+ "schema" : {"items" : true },
64
+ "tests" : [
65
+ {
66
+ "description" : " any array is valid" ,
67
+ "data" : [ 1 , " foo" , true ],
68
+ "valid" : true
69
+ },
70
+ {
71
+ "description" : " empty array is valid" ,
72
+ "data" : [],
73
+ "valid" : true
74
+ }
75
+ ]
76
+ },
77
+ {
78
+ "description" : " items with boolean schema (false)" ,
79
+ "schema" : {"items" : false },
80
+ "tests" : [
81
+ {
82
+ "description" : " any non-empty array is invalid" ,
83
+ "data" : [ 1 , " foo" , true ],
84
+ "valid" : false
85
+ },
86
+ {
87
+ "description" : " empty array is valid" ,
88
+ "data" : [],
89
+ "valid" : true
90
+ }
91
+ ]
92
+ },
93
+ {
94
+ "description" : " items with boolean schemas" ,
95
+ "schema" : {
96
+ "items" : [true , false ]
97
+ },
98
+ "tests" : [
99
+ {
100
+ "description" : " array with one item is valid" ,
101
+ "data" : [ 1 ],
102
+ "valid" : true
103
+ },
104
+ {
105
+ "description" : " array with two items is invalid" ,
106
+ "data" : [ 1 , " foo" ],
107
+ "valid" : false
108
+ },
109
+ {
110
+ "description" : " empty array is valid" ,
111
+ "data" : [],
112
+ "valid" : true
113
+ }
114
+ ]
60
115
}
61
116
]
You can’t perform that action at this time.
0 commit comments