Skip to content

Commit

Permalink
test when $dynamicRef references a boolean schema
Browse files Browse the repository at this point in the history
  • Loading branch information
karenetheridge committed Nov 12, 2023
1 parent 95fe6ca commit d4af8ee
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions tests/draft2020-12/dynamicRef.json
Original file line number Diff line number Diff line change
Expand Up @@ -726,5 +726,32 @@
"valid": false
}
]
},
{
"description": "$dynamicRef points to a boolean schema",
"schema": {
"$defs": {
"boolean": true
},
"type": "object",
"properties": {
"true": {
"$dynamicRef": "#/$defs/boolean"
},
"false": false
}
},
"tests": [
{
"description": "follow $dynamicRef to a true schema",
"data": { "true": 1 },
"valid": true
},
{
"description": "false schema",
"data": { "false": 1 },
"valid": false
}
]
}
]

0 comments on commit d4af8ee

Please sign in to comment.