summaryrefslogtreecommitdiff
path: root/tests/draft2020-12/optional/format/time.json
diff options
context:
space:
mode:
Diffstat (limited to 'tests/draft2020-12/optional/format/time.json')
-rw-r--r--tests/draft2020-12/optional/format/time.json23
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/draft2020-12/optional/format/time.json b/tests/draft2020-12/optional/format/time.json
new file mode 100644
index 0000000..4ec8a01
--- /dev/null
+++ b/tests/draft2020-12/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
+ }
+ ]
+ }
+]