-
-
Notifications
You must be signed in to change notification settings - Fork 208
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
dfcea62
commit dab94fa
Showing
2 changed files
with
31 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"$id": "http://localhost:1234/draft2019-09/dependentRequired.json", | ||
"$schema": "https://json-schema.org/draft/2019-09/schema", | ||
"dependentRequired": { | ||
"foo": ["bar"] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
[ | ||
{ | ||
"description": "refs to future drafts are processed as future drafts", | ||
"schema": { | ||
"type": "object", | ||
"allOf": [ | ||
{ "properties": { "foo": true } }, | ||
{ "$ref": "http://localhost:1234/draft2019-09/dependentRequired.json" } | ||
] | ||
}, | ||
"tests": [ | ||
{ | ||
"description": "missing bar is invalid", | ||
"data": {"foo": "any value"}, | ||
"valid": false | ||
}, | ||
{ | ||
"description": "present bar is valid", | ||
"data": {"foo": "any value", "bar": "also any value"}, | ||
"valid": true | ||
} | ||
] | ||
} | ||
] |