summaryrefslogtreecommitdiffstats
path: root/src/rapidjson/bin/jsonschema/tests/draft3/maximum.json
diff options
context:
space:
mode:
Diffstat (limited to 'src/rapidjson/bin/jsonschema/tests/draft3/maximum.json')
-rw-r--r--src/rapidjson/bin/jsonschema/tests/draft3/maximum.json42
1 files changed, 42 insertions, 0 deletions
diff --git a/src/rapidjson/bin/jsonschema/tests/draft3/maximum.json b/src/rapidjson/bin/jsonschema/tests/draft3/maximum.json
new file mode 100644
index 000000000..86c7b89c9
--- /dev/null
+++ b/src/rapidjson/bin/jsonschema/tests/draft3/maximum.json
@@ -0,0 +1,42 @@
+[
+ {
+ "description": "maximum validation",
+ "schema": {"maximum": 3.0},
+ "tests": [
+ {
+ "description": "below the maximum is valid",
+ "data": 2.6,
+ "valid": true
+ },
+ {
+ "description": "above the maximum is invalid",
+ "data": 3.5,
+ "valid": false
+ },
+ {
+ "description": "ignores non-numbers",
+ "data": "x",
+ "valid": true
+ }
+ ]
+ },
+ {
+ "description": "exclusiveMaximum validation",
+ "schema": {
+ "maximum": 3.0,
+ "exclusiveMaximum": true
+ },
+ "tests": [
+ {
+ "description": "below the maximum is still valid",
+ "data": 2.2,
+ "valid": true
+ },
+ {
+ "description": "boundary point is invalid",
+ "data": 3.0,
+ "valid": false
+ }
+ ]
+ }
+]