-
Notifications
You must be signed in to change notification settings - Fork 157
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
Fix. Add kwargs to plugin methods. #507
Conversation
It fixes problem with post_get raising error when namespace parameter is passed to get method.
Codecov Report
@@ Coverage Diff @@
## master #507 +/- ##
=======================================
Coverage 99.13% 99.13%
=======================================
Files 13 13
Lines 1043 1043
Branches 116 116
=======================================
Hits 1034 1034
Misses 9 9
Continue to review full report at Codecov.
|
Hey @dmtr can you please add a snippet to reproduce this and also tests for the changes? |
Hi!
It raises error
|
Looks good to me. Thanks for the contribution @dmtr ! |
tests/acceptance/test_plugins.py
Outdated
@pytest.mark.parametrize( | ||
"key,value,namespace", [("a", 1, None), ("b", 2, "test")], | ||
) | ||
async def test_set_and_get(self, memory_cache, key, value, namespace): |
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.
the case of not having a namespace is already tested above so we are good for the first case. Let's leave only one test where we pass the namespace explicitly and then we are ready to merge :)
@dmtr once you've changed the test as I mentioned please remember to do |
It fixes next problem: if for example namespace parameter is passed to
get
method, thenpost_get
method raises unexpected keyword argument error.