split composite invalid case into independent testcases

- the composite case proved that one type check failed not all of them
This commit is contained in:
alexmmm 2013-07-16 00:46:20 +02:00
parent d97cf3ce89
commit cd0d3a9e26

View File

@ -16,23 +16,83 @@ class BasicTypesTest extends BaseTestCase
return array(
array(
'{
"string":null,
"number":null,
"integer":null,
"boolean":null,
"object":null,
"array":null,
"string":null
}',
'{
"type":"object",
"properties": {
"string":{"type":"string"}
},
"additionalProperties":false
}'
),
array(
'{
"number":null
}',
'{
"type":"object",
"properties": {
"number":{"type":"number"}
},
"additionalProperties":false
}'
),
array(
'{
"integer":null
}',
'{
"type":"object",
"properties": {
"integer":{"type":"integer"}
},
"additionalProperties":false
}'
),
array(
'{
"boolean":null
}',
'{
"type":"object",
"properties": {
"boolean":{"type":"boolean"}
},
"additionalProperties":false
}'
),
array(
'{
"object":null
}',
'{
"type":"object",
"properties": {
"object":{"type":"object"}
},
"additionalProperties":false
}'
),
array(
'{
"array":null
}',
'{
"type":"object",
"properties": {
"array":{"type":"array"}
},
"additionalProperties":false
}'
),
array(
'{
"null":1
}',
'{
"type":"object",
"properties": {
"string":{"type":"string"},
"number":{"type":"number"},
"integer":{"type":"integer"},
"boolean":{"type":"boolean"},
"object":{"type":"object"},
"array":{"type":"array"},
"null":{"type":"null"}
},
"additionalProperties":false