Debian Codegraph @

spec/JSON-Schema-Test-Suite/tests/draft2020-12/infinite-loop-detection.json

raw ◀ ▶
1 Debian patch touch this file
•1 [
2 {
3 "description": "evaluating the same schema location against the same data location twice is not a sign of an infinite loop",
4 "schema": {
5 "$defs": {
6 "int": { "type": "integer" }
7 },
8 "allOf": [
9 {
10 "properties": {
11 "foo": {
12 "$ref": "#/$defs/int"
13 }
14 }
15 },
16 {
17 "additionalProperties": {
18 "$ref": "#/$defs/int"
19 }
20 }
21 ]
22 },
23 "tests": [
24 {
25 "description": "passing case",
26 "data": { "foo": 1 },
27 "valid": true
28 },
29 {
30 "description": "failing case",
31 "data": { "foo": "a string" },
32 "valid": false
33 }
34 ]
35 }
36 ]