summaryrefslogtreecommitdiff
path: root/json/tests/draft7/enum.json
diff options
context:
space:
mode:
authorJulian Berman <Julian@GrayVines.com>2019-03-31 09:38:07 -0400
committerJulian Berman <Julian@GrayVines.com>2019-03-31 09:38:07 -0400
commit14710c64f2df383e00366b2db839f40ae0d691c8 (patch)
tree898682feb61fe3c35f670aaca6cf0abf0c7b8461 /json/tests/draft7/enum.json
parent4b2d27602a9fd0c13fd3f3b1fe89a8a297b144fd (diff)
parenteb60af03a05771bdfa07256b54b71aef8c055a3b (diff)
downloadjsonschema-14710c64f2df383e00366b2db839f40ae0d691c8.tar.gz
Merge commit 'eb60af03a05771bdfa07256b54b71aef8c055a3b'
* commit 'eb60af03a05771bdfa07256b54b71aef8c055a3b': Squashed 'json/' changes from 3c3881a..15ba997
Diffstat (limited to 'json/tests/draft7/enum.json')
-rw-r--r--json/tests/draft7/enum.json23
1 files changed, 23 insertions, 0 deletions
diff --git a/json/tests/draft7/enum.json b/json/tests/draft7/enum.json
index 8fb9d7a..04a92a4 100644
--- a/json/tests/draft7/enum.json
+++ b/json/tests/draft7/enum.json
@@ -68,5 +68,28 @@
"valid": false
}
]
+ },
+ {
+ "description": "enum with escaped characters",
+ "schema": {
+ "enum": ["foo\nbar", "foo\rbar"]
+ },
+ "tests": [
+ {
+ "description": "member 1 is valid",
+ "data": "foo\nbar",
+ "valid": true
+ },
+ {
+ "description": "member 2 is valid",
+ "data": "foo\rbar",
+ "valid": true
+ },
+ {
+ "description": "another string is invalid",
+ "data": "abc",
+ "valid": false
+ }
+ ]
}
]