-
-
Notifications
You must be signed in to change notification settings - Fork 133
WIP Add any-of #288
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WIP Add any-of #288
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know it's WIP. Looks okay just some minor fixes needed
Codecov Report
@@ Coverage Diff @@
## master #288 +/- ##
==========================================
- Coverage 96.75% 95.86% -0.89%
==========================================
Files 122 122
Lines 2431 2465 +34
==========================================
+ Hits 2352 2363 +11
- Misses 79 102 +23
Continue to review full report at Codecov.
|
pass | ||
else: | ||
if properties is not None: | ||
log.warning("multiple valid anyOf schemas found") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's allowed to have many valid schemas for anyof and properties need to be added rather than replaced
@@ -529,6 +529,80 @@ def test_unambiguous_one_of(self, value, validator_factory): | |||
|
|||
assert result is None | |||
|
|||
@pytest.mark.parametrize('value', [Model(), ]) | |||
def test_object_multiple_any_of(self, value, validator_factory): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Multiple valid schemas are allowed for anyOf. It shouldn't raise error.
@allcaps -- Really appreciate you taking this one on! |
I'd love to see this PR merged. @allcaps Will you be able to finish it? |
Nope, the project I was working that required any-of is canceled so I lost my funding (and motivation). Anyone who likes to work on this, go ahead! |
Closing in favor of #423 |
No description provided.