Debian Codegraph @

t/additional-tests-draft2019-09/annotation-collection.json

raw
1 [
2 {
3 "description": "annotations come from an allOf, unevaluated is a sibling",
4 "schema": {
5 "allOf": [ { "properties": { "foo": true } } ],
6 "unevaluatedProperties": false
7 },
8 "tests": [
9 {
10 "description": "properties evaluated from allOf",
11 "data": { "foo": 1 },
12 "valid": true
13 },
14 {
15 "description": "extra property",
16 "data": { "bar": 1 },
17 "valid": false
18 }
19 ]
20 },
21 {
22 "description": "annotations from adjacent keywords, unevaluated is a sibling",
23 "schema": {
24 "properties": { "foo": true },
25 "unevaluatedProperties": false
26 },
27 "tests": [
28 {
29 "description": "properties evaluated from additionalProperties",
30 "data": { "foo": 1 },
31 "valid": true
32 },
33 {
34 "description": "extra property",
35 "data": { "bar": 1 },
36 "valid": false
37 }
38 ]
39 },
40 {
41 "description": "annotations come from an allOf, unevaluated is in an allOf",
42 "schema": {
43 "allOf": [ { "properties": { "foo": true } } ],
44 "anyOf": [ { "unevaluatedProperties": false } ]
45 },
46 "tests": [
47 {
48 "description": "properties evaluated from allOf, but unevaluated is buried",
49 "data": { "foo": 1 },
50 "valid": false
51 },
52 {
53 "description": "no properties",
54 "data": {},
55 "valid": true
56 }
57 ]
58 },
59 {
60 "description": "annotations from adjacent keywords, unevaluated is in an allOf",
61 "schema": {
62 "anyOf": [ { "properties": { "foo": true } } ],
63 "allOf": [ { "unevaluatedProperties": false } ]
64 },
65 "tests": [
66 {
67 "description": "properties evaluated from additionalProperties, but unevaluated is buried",
68 "data": { "foo": 1 },
69 "valid": false
70 },
71 {
72 "description": "no properties",
73 "data": {},
74 "valid": true
75 }
76 ]
77 },
78 {
79 "description": "collect annotations inside a 'not', even if collection is disabled",
80 "schema": {
81 "not": {
82 "$comment": "this subschema must still produce annotations internally, even though the 'not' will ultimately discard them",
83 "anyOf": [
84 true,
85 { "properties": { "foo": true } }
86 ],
87 "unevaluatedProperties": false
88 }
89 },
90 "tests": [
91 {
92 "description": "unevaluated property",
93 "data": { "bar": 1 },
94 "valid": true
95 },
96 {
97 "description": "annotations are still collected inside a 'not'",
98 "data": { "foo": 1 },
99 "valid": false
100 }
101 ]
102 }
103 ]