validator: check unimplemented keyword after resolve nested schemas

This commit is contained in:
Patrick Boettcher 2016-12-27 00:42:56 +01:00
parent 9b3769a132
commit 6c0620a90b

View File

@ -538,11 +538,6 @@ void json_validator::validate_object(json &instance, const json &schema, const s
void json_validator::validate(json &instance, const json &schema_, const std::string &name)
{
not_yet_implemented(schema_, "allOf", "all");
not_yet_implemented(schema_, "anyOf", "all");
not_yet_implemented(schema_, "oneOf", "all");
not_yet_implemented(schema_, "not", "all");
const json *schema = &schema_;
do {
@ -558,6 +553,11 @@ void json_validator::validate(json &instance, const json &schema_, const std::st
break;
} while (1); // loop in case of nested refs
not_yet_implemented(*schema, "allOf", "all");
not_yet_implemented(*schema, "anyOf", "all");
not_yet_implemented(*schema, "oneOf", "all");
not_yet_implemented(*schema, "not", "all");
validate_enum(instance, *schema, name);
switch (instance.type()) {