cuelang.org/go@v0.13.0/encoding/jsonschema/testdata/external/tests/draft2020-12/optional/refOfUnknownKeyword.json (about) 1 [ 2 { 3 "description": "reference of a root arbitrary keyword ", 4 "schema": { 5 "$schema": "https://json-schema.org/draft/2020-12/schema", 6 "unknown-keyword": { 7 "type": "integer" 8 }, 9 "properties": { 10 "bar": { 11 "$ref": "#/unknown-keyword" 12 } 13 } 14 }, 15 "tests": [ 16 { 17 "description": "match", 18 "data": { 19 "bar": 3 20 }, 21 "valid": true 22 }, 23 { 24 "description": "mismatch", 25 "data": { 26 "bar": true 27 }, 28 "valid": false 29 } 30 ] 31 }, 32 { 33 "description": "reference of an arbitrary keyword of a sub-schema", 34 "schema": { 35 "$schema": "https://json-schema.org/draft/2020-12/schema", 36 "properties": { 37 "foo": { 38 "unknown-keyword": { 39 "type": "integer" 40 } 41 }, 42 "bar": { 43 "$ref": "#/properties/foo/unknown-keyword" 44 } 45 } 46 }, 47 "tests": [ 48 { 49 "description": "match", 50 "data": { 51 "bar": 3 52 }, 53 "valid": true 54 }, 55 { 56 "description": "mismatch", 57 "data": { 58 "bar": true 59 }, 60 "valid": false 61 } 62 ] 63 }, 64 { 65 "description": "reference internals of known non-applicator", 66 "schema": { 67 "$schema": "https://json-schema.org/draft/2020-12/schema", 68 "$id": "/base", 69 "examples": [ 70 { 71 "type": "string" 72 } 73 ], 74 "$ref": "#/examples/0" 75 }, 76 "tests": [ 77 { 78 "description": "match", 79 "data": "a string", 80 "valid": true 81 }, 82 { 83 "description": "mismatch", 84 "data": 42, 85 "valid": false 86 } 87 ] 88 } 89 ]