Skip to content

Commit

Permalink
json sample schema files for tests
Browse files Browse the repository at this point in the history
  • Loading branch information
pabloem committed Nov 22, 2022
1 parent 6add8d0 commit 2d77e7a
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"properties": {
"booleanProp": {
"type": "boolean"
},
"integerProp": {
"type": "integer"
},
"numberProp": {
"type": "number"
},
"stringProp": {
"type": "string"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
{
"$id": "https://example.com/arrays.schema.json",
"description": "A representation of a person, company, organization, or place",
"type": "object",
"properties": {
"fruits": {
"type": "array",
"items": {
"type": "string"
}
},
"vegetables": {
"type": "array",
"items": { "$ref": "#/$defs/veggie" }
}
},
"$defs": {
"veggie": {
"type": "object",
"required": [ "veggieName", "veggieLike" ],
"properties": {
"veggieName": {
"type": "string",
"description": "The name of the vegetable."
},
"veggieLike": {
"type": "boolean",
"description": "Do I like this vegetable?"
}
}
}
}
}

0 comments on commit 2d77e7a

Please sign in to comment.