summaryrefslogtreecommitdiff
path: root/json/tests/draft7/optional/format/date-time.json
diff options
context:
space:
mode:
authorJulian Berman <Julian@GrayVines.com>2021-10-07 09:13:10 -0400
committerJulian Berman <Julian@GrayVines.com>2021-10-07 09:13:10 -0400
commitb59060c1d88beeecd4eef0fcf09fa1a87580fb38 (patch)
tree163b87be0c45e5cb31b7068acfba01f1755f2949 /json/tests/draft7/optional/format/date-time.json
parent08f88a6ff67f51b971c210683f73fd96da998d29 (diff)
parentcf886386cc0996df6743b425f74675a6d8a1a9ca (diff)
downloadjsonschema-b59060c1d88beeecd4eef0fcf09fa1a87580fb38.tar.gz
Merge commit 'cf886386cc0996df6743b425f74675a6d8a1a9ca'
* commit 'cf886386cc0996df6743b425f74675a6d8a1a9ca': Squashed 'json/' changes from 20c1bb1d9..54440eab4
Diffstat (limited to 'json/tests/draft7/optional/format/date-time.json')
-rw-r--r--json/tests/draft7/optional/format/date-time.json37
1 files changed, 36 insertions, 1 deletions
diff --git a/json/tests/draft7/optional/format/date-time.json b/json/tests/draft7/optional/format/date-time.json
index 5f911ef..119179c 100644
--- a/json/tests/draft7/optional/format/date-time.json
+++ b/json/tests/draft7/optional/format/date-time.json
@@ -1,9 +1,39 @@
[
{
"description": "validation of date-time strings",
- "schema": {"format": "date-time"},
+ "schema": { "format": "date-time" },
"tests": [
{
+ "description": "all string formats ignore integers",
+ "data": 12,
+ "valid": true
+ },
+ {
+ "description": "all string formats ignore floats",
+ "data": 13.7,
+ "valid": true
+ },
+ {
+ "description": "all string formats ignore objects",
+ "data": {},
+ "valid": true
+ },
+ {
+ "description": "all string formats ignore arrays",
+ "data": [],
+ "valid": true
+ },
+ {
+ "description": "all string formats ignore booleans",
+ "data": false,
+ "valid": true
+ },
+ {
+ "description": "all string formats ignore nulls",
+ "data": null,
+ "valid": true
+ },
+ {
"description": "a valid date-time string",
"data": "1963-06-19T08:30:06.283185Z",
"valid": true
@@ -34,6 +64,11 @@
"valid": false
},
{
+ "description": "an invalid closing Z after time-zone offset",
+ "data": "1963-06-19T08:30:06.28123+01:00Z",
+ "valid": false
+ },
+ {
"description": "an invalid date-time string",
"data": "06/19/1963 08:30:06 PST",
"valid": false