diff options
Diffstat (limited to 'src/s3select/rapidjson/bin/jsonschema/tests/draft4/required.json')
-rw-r--r-- | src/s3select/rapidjson/bin/jsonschema/tests/draft4/required.json | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/src/s3select/rapidjson/bin/jsonschema/tests/draft4/required.json b/src/s3select/rapidjson/bin/jsonschema/tests/draft4/required.json new file mode 100644 index 000000000..612f73f34 --- /dev/null +++ b/src/s3select/rapidjson/bin/jsonschema/tests/draft4/required.json @@ -0,0 +1,39 @@ +[ + { + "description": "required validation", + "schema": { + "properties": { + "foo": {}, + "bar": {} + }, + "required": ["foo"] + }, + "tests": [ + { + "description": "present required property is valid", + "data": {"foo": 1}, + "valid": true + }, + { + "description": "non-present required property is invalid", + "data": {"bar": 1}, + "valid": false + } + ] + }, + { + "description": "required default validation", + "schema": { + "properties": { + "foo": {} + } + }, + "tests": [ + { + "description": "not required by default", + "data": {}, + "valid": true + } + ] + } +] |