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

     1  [
     2  	{
     3  		"description": "refs to future drafts are processed as future drafts",
     4  		"schema": {
     5  			"$schema": "https://json-schema.org/draft/2019-09/schema",
     6  			"type": "array",
     7  			"$ref": "http://localhost:1234/draft2020-12/prefixItems.json"
     8  		},
     9  		"skip": {
    10  			"v2": "extract error: cannot compile resulting schema: invalid import path: \"localhost:1234/draft2020-12/prefixItems.json:prefixItems\":\n    generated.cue:1:8\n",
    11  			"v3": "extract error: cannot compile resulting schema: invalid import path: \"localhost:1234/draft2020-12/prefixItems.json:prefixItems\":\n    generated.cue:1:8\n"
    12  		},
    13  		"tests": [
    14  			{
    15  				"description": "first item not a string is invalid",
    16  				"comment": "if the implementation is not processing the $ref as a 2020-12 schema, this test will fail",
    17  				"data": [
    18  					1,
    19  					2,
    20  					3
    21  				],
    22  				"valid": false,
    23  				"skip": {
    24  					"v2": "could not compile schema",
    25  					"v3": "could not compile schema"
    26  				}
    27  			},
    28  			{
    29  				"description": "first item is a string is valid",
    30  				"data": [
    31  					"a string",
    32  					1,
    33  					2,
    34  					3
    35  				],
    36  				"valid": true,
    37  				"skip": {
    38  					"v2": "could not compile schema",
    39  					"v3": "could not compile schema"
    40  				}
    41  			}
    42  		]
    43  	},
    44  	{
    45  		"description": "refs to historic drafts are processed as historic drafts",
    46  		"schema": {
    47  			"type": "object",
    48  			"allOf": [
    49  				{
    50  					"properties": {
    51  						"foo": true
    52  					}
    53  				},
    54  				{
    55  					"$ref": "http://localhost:1234/draft7/ignore-dependentRequired.json"
    56  				}
    57  			]
    58  		},
    59  		"skip": {
    60  			"v2": "extract error: cannot compile resulting schema: invalid import path: \"localhost:1234/draft7/ignore-dependentRequired.json:schema\":\n    generated.cue:1:8\n",
    61  			"v3": "extract error: cannot compile resulting schema: invalid import path: \"localhost:1234/draft7/ignore-dependentRequired.json:schema\":\n    generated.cue:1:8\n"
    62  		},
    63  		"tests": [
    64  			{
    65  				"description": "missing bar is valid",
    66  				"comment": "if the implementation is not processing the $ref as a draft 7 schema, this test will fail",
    67  				"data": {
    68  					"foo": "any value"
    69  				},
    70  				"valid": true,
    71  				"skip": {
    72  					"v2": "could not compile schema",
    73  					"v3": "could not compile schema"
    74  				}
    75  			}
    76  		]
    77  	}
    78  ]