| •1 |
{ |
| 2 |
"null schema": null, |
| 3 |
"boolean schema": true, |
| 4 |
"integer schema": 1, |
| 5 |
"float schema": 3.14, |
| 6 |
"string schema": "foo", |
| 7 |
"array schema": [], |
| 8 |
"illegal keyword": { |
| 9 |
"foo": 123 |
| 10 |
}, |
| 11 |
"nullable not boolean": { |
| 12 |
"nullable": 123 |
| 13 |
}, |
| 14 |
"definitions not object": { |
| 15 |
"definitions": 123 |
| 16 |
}, |
| 17 |
"definition not object": { |
| 18 |
"definitions": { |
| 19 |
"foo": 123 |
| 20 |
} |
| 21 |
}, |
| 22 |
"non-root definitions": { |
| 23 |
"definitions": { |
| 24 |
"foo": { |
| 25 |
"definitions": { |
| 26 |
"x": {} |
| 27 |
} |
| 28 |
} |
| 29 |
} |
| 30 |
}, |
| 31 |
"ref not string": { |
| 32 |
"ref": 123 |
| 33 |
}, |
| 34 |
"ref but no definitions": { |
| 35 |
"ref": "foo" |
| 36 |
}, |
| 37 |
"ref to non-existent definition": { |
| 38 |
"definitions": {}, |
| 39 |
"ref": "foo" |
| 40 |
}, |
| 41 |
"sub-schema ref to non-existent definition": { |
| 42 |
"definitions": {}, |
| 43 |
"elements": { |
| 44 |
"ref": "foo" |
| 45 |
} |
| 46 |
}, |
| 47 |
"type not string": { |
| 48 |
"type": 123 |
| 49 |
}, |
| 50 |
"type not valid string value": { |
| 51 |
"type": "foo" |
| 52 |
}, |
| 53 |
"enum not array": { |
| 54 |
"enum": 123 |
| 55 |
}, |
| 56 |
"enum empty array": { |
| 57 |
"enum": [] |
| 58 |
}, |
| 59 |
"enum not array of strings": { |
| 60 |
"enum": [ |
| 61 |
"foo", |
| 62 |
123, |
| 63 |
"baz" |
| 64 |
] |
| 65 |
}, |
| 66 |
"enum contains duplicates": { |
| 67 |
"enum": [ |
| 68 |
"foo", |
| 69 |
"bar", |
| 70 |
"foo" |
| 71 |
] |
| 72 |
}, |
| 73 |
"elements not object": { |
| 74 |
"elements": 123 |
| 75 |
}, |
| 76 |
"elements not correct schema": { |
| 77 |
"elements": { |
| 78 |
"definitions": { |
| 79 |
"x": {} |
| 80 |
} |
| 81 |
} |
| 82 |
}, |
| 83 |
"properties not object": { |
| 84 |
"properties": 123 |
| 85 |
}, |
| 86 |
"properties value not correct schema": { |
| 87 |
"properties": { |
| 88 |
"foo": { |
| 89 |
"definitions": { |
| 90 |
"x": {} |
| 91 |
} |
| 92 |
} |
| 93 |
} |
| 94 |
}, |
| 95 |
"optionalProperties not object": { |
| 96 |
"optionalProperties": 123 |
| 97 |
}, |
| 98 |
"optionalProperties value not correct schema": { |
| 99 |
"optionalProperties": { |
| 100 |
"foo": { |
| 101 |
"definitions": { |
| 102 |
"x": {} |
| 103 |
} |
| 104 |
} |
| 105 |
} |
| 106 |
}, |
| 107 |
"additionalProperties not boolean": { |
| 108 |
"properties": {}, |
| 109 |
"additionalProperties": 123 |
| 110 |
}, |
| 111 |
"properties shares keys with optionalProperties": { |
| 112 |
"properties": { |
| 113 |
"foo": {}, |
| 114 |
"bar": {} |
| 115 |
}, |
| 116 |
"optionalProperties": { |
| 117 |
"foo": {}, |
| 118 |
"baz": {} |
| 119 |
} |
| 120 |
}, |
| 121 |
"values not object": { |
| 122 |
"values": 123 |
| 123 |
}, |
| 124 |
"values not correct schema": { |
| 125 |
"values": { |
| 126 |
"definitions": { |
| 127 |
"x": {} |
| 128 |
} |
| 129 |
} |
| 130 |
}, |
| 131 |
"discriminator not string": { |
| 132 |
"discriminator": 123, |
| 133 |
"mapping": {} |
| 134 |
}, |
| 135 |
"mapping not object": { |
| 136 |
"discriminator": "foo", |
| 137 |
"mapping": 123 |
| 138 |
}, |
| 139 |
"mapping value not correct schema": { |
| 140 |
"discriminator": "foo", |
| 141 |
"mapping": { |
| 142 |
"x": { |
| 143 |
"properties": {}, |
| 144 |
"definitions": { |
| 145 |
"x": {} |
| 146 |
} |
| 147 |
} |
| 148 |
} |
| 149 |
}, |
| 150 |
"mapping value not of properties form": { |
| 151 |
"discriminator": "foo", |
| 152 |
"mapping": { |
| 153 |
"x": {} |
| 154 |
} |
| 155 |
}, |
| 156 |
"mapping value has nullable set to true": { |
| 157 |
"discriminator": "foo", |
| 158 |
"mapping": { |
| 159 |
"x": { |
| 160 |
"nullable": true, |
| 161 |
"properties": { |
| 162 |
"bar": {} |
| 163 |
} |
| 164 |
} |
| 165 |
} |
| 166 |
}, |
| 167 |
"discriminator shares keys with mapping properties": { |
| 168 |
"discriminator": "foo", |
| 169 |
"mapping": { |
| 170 |
"x": { |
| 171 |
"properties": { |
| 172 |
"foo": {} |
| 173 |
} |
| 174 |
} |
| 175 |
} |
| 176 |
}, |
| 177 |
"discriminator shares keys with mapping optionalProperties": { |
| 178 |
"discriminator": "foo", |
| 179 |
"mapping": { |
| 180 |
"x": { |
| 181 |
"optionalProperties": { |
| 182 |
"foo": {} |
| 183 |
} |
| 184 |
} |
| 185 |
} |
| 186 |
}, |
| 187 |
"invalid form - ref and type": { |
| 188 |
"definitions": { |
| 189 |
"foo": {} |
| 190 |
}, |
| 191 |
"ref": "foo", |
| 192 |
"type": "uint32" |
| 193 |
}, |
| 194 |
"invalid form - type and enum": { |
| 195 |
"type": "uint32", |
| 196 |
"enum": [ |
| 197 |
"foo" |
| 198 |
] |
| 199 |
}, |
| 200 |
"invalid form - enum and elements": { |
| 201 |
"enum": [ |
| 202 |
"foo" |
| 203 |
], |
| 204 |
"elements": {} |
| 205 |
}, |
| 206 |
"invalid form - elements and properties": { |
| 207 |
"elements": {}, |
| 208 |
"properties": {} |
| 209 |
}, |
| 210 |
"invalid form - elements and optionalProperties": { |
| 211 |
"elements": {}, |
| 212 |
"optionalProperties": {} |
| 213 |
}, |
| 214 |
"invalid form - elements and additionalProperties": { |
| 215 |
"elements": {}, |
| 216 |
"additionalProperties": true |
| 217 |
}, |
| 218 |
"invalid form - additionalProperties alone": { |
| 219 |
"additionalProperties": true |
| 220 |
}, |
| 221 |
"invalid form - properties and values": { |
| 222 |
"properties": {}, |
| 223 |
"values": {} |
| 224 |
}, |
| 225 |
"invalid form - values and discriminator": { |
| 226 |
"values": {}, |
| 227 |
"discriminator": "foo", |
| 228 |
"mapping": {} |
| 229 |
}, |
| 230 |
"invalid form - discriminator alone": { |
| 231 |
"discriminator": "foo" |
| 232 |
}, |
| 233 |
"invalid form - mapping alone": { |
| 234 |
"mapping": {} |
| 235 |
} |
| 236 |
} |