cuelang.org/go@v0.13.0/encoding/jsonschema/testdata/external/tests/draft2019-09/optional/unknownKeyword.json (about)

     1  [
     2  	{
     3  		"description": "$id inside an unknown keyword is not a real identifier",
     4  		"comment": "the implementation must not be confused by an $id in locations we do not know how to parse",
     5  		"schema": {
     6  			"$schema": "https://json-schema.org/draft/2019-09/schema",
     7  			"$defs": {
     8  				"id_in_unknown0": {
     9  					"not": {
    10  						"array_of_schemas": [
    11  							{
    12  								"$id": "https://localhost:1234/draft2019-09/unknownKeyword/my_identifier.json",
    13  								"type": "null"
    14  							}
    15  						]
    16  					}
    17  				},
    18  				"real_id_in_schema": {
    19  					"$id": "https://localhost:1234/draft2019-09/unknownKeyword/my_identifier.json",
    20  					"type": "string"
    21  				},
    22  				"id_in_unknown1": {
    23  					"not": {
    24  						"object_of_schemas": {
    25  							"foo": {
    26  								"$id": "https://localhost:1234/draft2019-09/unknownKeyword/my_identifier.json",
    27  								"type": "integer"
    28  							}
    29  						}
    30  					}
    31  				}
    32  			},
    33  			"anyOf": [
    34  				{
    35  					"$ref": "#/$defs/id_in_unknown0"
    36  				},
    37  				{
    38  					"$ref": "#/$defs/id_in_unknown1"
    39  				},
    40  				{
    41  					"$ref": "https://localhost:1234/draft2019-09/unknownKeyword/my_identifier.json"
    42  				}
    43  			]
    44  		},
    45  		"tests": [
    46  			{
    47  				"description": "type matches second anyOf, which has a real schema in it",
    48  				"data": "a string",
    49  				"valid": true
    50  			},
    51  			{
    52  				"description": "type matches non-schema in first anyOf",
    53  				"data": null,
    54  				"valid": false
    55  			},
    56  			{
    57  				"description": "type matches non-schema in third anyOf",
    58  				"data": 1,
    59  				"valid": false
    60  			}
    61  		]
    62  	}
    63  ]