summaryrefslogtreecommitdiff
path: root/json/tests/draft7/optional/format/time.json
diff options
context:
space:
mode:
Diffstat (limited to 'json/tests/draft7/optional/format/time.json')
-rw-r--r--json/tests/draft7/optional/format/time.json23
1 files changed, 23 insertions, 0 deletions
diff --git a/json/tests/draft7/optional/format/time.json b/json/tests/draft7/optional/format/time.json
new file mode 100644
index 0000000..4ec8a01
--- /dev/null
+++ b/json/tests/draft7/optional/format/time.json
@@ -0,0 +1,23 @@
+[
+ {
+ "description": "validation of time strings",
+ "schema": {"format": "time"},
+ "tests": [
+ {
+ "description": "a valid time string",
+ "data": "08:30:06.283185Z",
+ "valid": true
+ },
+ {
+ "description": "an invalid time string",
+ "data": "08:30:06 PST",
+ "valid": false
+ },
+ {
+ "description": "only RFC3339 not all of ISO 8601 are valid",
+ "data": "01:01:01,1111",
+ "valid": false
+ }
+ ]
+ }
+]