diff options
author | Julian Berman <Julian@GrayVines.com> | 2017-12-08 18:46:40 -0500 |
---|---|---|
committer | Julian Berman <Julian@GrayVines.com> | 2017-12-08 18:46:40 -0500 |
commit | 0971b05f0c9e2fc7272e377e2be09d07d8747952 (patch) | |
tree | 02df1dd495638be2c26340006d0c6efa8d24d61f /json/tests/draft7/boolean_schema.json | |
parent | 603c6c3691c5995aee0ec537044dbfc6c7173a62 (diff) | |
parent | 6f29c6b58d6d75527281d8dfa413234ce6df8368 (diff) | |
download | jsonschema-0971b05f0c9e2fc7272e377e2be09d07d8747952.tar.gz |
Merge commit '6f29c6b58d6d75527281d8dfa413234ce6df8368'
* commit '6f29c6b58d6d75527281d8dfa413234ce6df8368':
Squashed 'json/' changes from 9567c58..86f965e
Diffstat (limited to 'json/tests/draft7/boolean_schema.json')
-rw-r--r-- | json/tests/draft7/boolean_schema.json | 104 |
1 files changed, 104 insertions, 0 deletions
diff --git a/json/tests/draft7/boolean_schema.json b/json/tests/draft7/boolean_schema.json new file mode 100644 index 0000000..6d40f23 --- /dev/null +++ b/json/tests/draft7/boolean_schema.json @@ -0,0 +1,104 @@ +[ + { + "description": "boolean schema 'true'", + "schema": true, + "tests": [ + { + "description": "number is valid", + "data": 1, + "valid": true + }, + { + "description": "string is valid", + "data": "foo", + "valid": true + }, + { + "description": "boolean true is valid", + "data": true, + "valid": true + }, + { + "description": "boolean false is valid", + "data": false, + "valid": true + }, + { + "description": "null is valid", + "data": null, + "valid": true + }, + { + "description": "object is valid", + "data": {"foo": "bar"}, + "valid": true + }, + { + "description": "empty object is valid", + "data": {}, + "valid": true + }, + { + "description": "array is valid", + "data": ["foo"], + "valid": true + }, + { + "description": "empty array is valid", + "data": [], + "valid": true + } + ] + }, + { + "description": "boolean schema 'false'", + "schema": false, + "tests": [ + { + "description": "number is invalid", + "data": 1, + "valid": false + }, + { + "description": "string is invalid", + "data": "foo", + "valid": false + }, + { + "description": "boolean true is invalid", + "data": true, + "valid": false + }, + { + "description": "boolean false is invalid", + "data": false, + "valid": false + }, + { + "description": "null is invalid", + "data": null, + "valid": false + }, + { + "description": "object is invalid", + "data": {"foo": "bar"}, + "valid": false + }, + { + "description": "empty object is invalid", + "data": {}, + "valid": false + }, + { + "description": "array is invalid", + "data": ["foo"], + "valid": false + }, + { + "description": "empty array is invalid", + "data": [], + "valid": false + } + ] + } +] |