mirror of https://github.com/lukechilds/node.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
50 lines
1.2 KiB
50 lines
1.2 KiB
10 years ago
|
[
|
||
|
{
|
||
|
"description": "invalid type for default",
|
||
|
"schema": {
|
||
|
"properties": {
|
||
|
"foo": {
|
||
|
"type": "integer",
|
||
|
"default": []
|
||
|
}
|
||
|
}
|
||
|
},
|
||
|
"tests": [
|
||
|
{
|
||
|
"description": "valid when property is specified",
|
||
|
"data": {"foo": 13},
|
||
|
"valid": true
|
||
|
},
|
||
|
{
|
||
|
"description": "still valid when the invalid default is used",
|
||
|
"data": {},
|
||
|
"valid": true
|
||
|
}
|
||
|
]
|
||
|
},
|
||
|
{
|
||
|
"description": "invalid string value for default",
|
||
|
"schema": {
|
||
|
"properties": {
|
||
|
"bar": {
|
||
|
"type": "string",
|
||
|
"minLength": 4,
|
||
|
"default": "bad"
|
||
|
}
|
||
|
}
|
||
|
},
|
||
|
"tests": [
|
||
|
{
|
||
|
"description": "valid when property is specified",
|
||
|
"data": {"bar": "good"},
|
||
|
"valid": true
|
||
|
},
|
||
|
{
|
||
|
"description": "still valid when the invalid default is used",
|
||
|
"data": {},
|
||
|
"valid": true
|
||
|
}
|
||
|
]
|
||
|
}
|
||
|
]
|