-
-
Notifications
You must be signed in to change notification settings - Fork 32.2k
bpo-40820: Add change version for Mock Call args
and kwargs
properties
#20519
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
Conversation
Hello, and thanks for your contribution! I'm a bot set up to make sure that the project can legally accept this contribution by verifying everyone involved has signed the PSF contributor agreement (CLA). Recognized GitHub usernameWe couldn't find a bugs.python.org (b.p.o) account corresponding to the following GitHub usernames: This might be simply due to a missing "GitHub Name" entry in one's b.p.o account settings. This is necessary for legal reasons before we can look at this contribution. Please follow the steps outlined in the CPython devguide to rectify this issue. You can check yourself to see if the CLA has been received. Thanks again for the contribution, we look forward to reviewing it! |
args
and kwargs
propertiesargs
and kwargs
properties
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.
Hi @gobisa, thanks for taking the time to improve the documentation!
Doc/library/unittest.mock.rst
Outdated
@@ -647,6 +647,10 @@ the *new_callable* argument to :func:`patch`. | |||
arguments and make more complex assertions. See | |||
:ref:`calls as tuples <calls-as-tuples>`. | |||
|
|||
.. versionchanged:: 3.8 | |||
Added the ``args`` and ``kwargs`` properties to more easily access the | |||
positional args and keyword args within a ``Call`` object tuple. |
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.
positional args and keyword args within a ``Call`` object tuple. | |
positional args and keyword args within a ``Call`` object. |
@@ -0,0 +1 @@ | |||
Add missing change version for ``args`` and ``kwargs`` mock call objects. Contributed by Andrew Gobis. |
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.
Document changes don't need a NEWS entry as they don't change the behaviour of Python but you should add your name to Misc/ACKS
.
Add self to `Misc/ACKS`
…nto fix-issue-40820
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.
👍
Should this change also be made to the 3.8 and 3.9 branches? |
I think it should, please sign the CLA as @the-knights-who-say-ni said :) |
Will do, but this is out of my control for now. |
What do you mean exactly? |
Closing this in favor of #21525. Sorry. |
https://bugs.python.org/issue40820