Skip to content

Commit

Permalink
Merge pull request #12 from maykinmedia/feature/schema-validation-update
Browse files Browse the repository at this point in the history
support 'allOf' and 'oneOf' in schema check
  • Loading branch information
annashamray authored Sep 28, 2023
2 parents 0ab2f49 + b0171c9 commit 3578b3c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions vng_api_common/oas.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,10 @@ def obj_has_shape(obj: Union[list, dict], schema: dict, resource: str) -> bool:
if "$ref" in prop_schema:
continue

# TODO Handling allOf and oneOf not yet implemented
if "allOf" in prop_schema or "oneOf" in prop_schema:
continue

# Allow None if property is nullable
if value is None:
if prop_schema.get("nullable", False):
Expand Down

0 comments on commit 3578b3c

Please sign in to comment.