]> granicus.if.org Git - python/commit
bpo-37972: unittest.mock._Call now passes on __getitem__ to the __getattr__ chaining...
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Thu, 12 Sep 2019 10:52:49 +0000 (03:52 -0700)
committerMichael Foord <voidspace@users.noreply.github.com>
Thu, 12 Sep 2019 10:52:49 +0000 (12:52 +0200)
commitdb0d8a5b2c803d30d9df436e00b6627ec8e09a13
tree4eb7a4ddb5ed695da5bb71a643ed20531fc824e5
parentf60fd95dcc189ace8c0a2177a394b9cc20389a1e
bpo-37972: unittest.mock._Call now passes on __getitem__ to the __getattr__ chaining so that call() can be subscriptable (GH-15565) (GH-15965)

* bpo-37972: unittest.mock._Call now passes on __getitem__ to the __getattr__ chaining so that call() can be subscriptable

* ðŸ“œðŸ¤– Added by blurb_it.

* Update 2019-08-28-21-40-12.bpo-37972.kP-n4L.rst

added name of the contributor

* bpo-37972: made all dunder methods chainable for _Call

* bpo-37972: delegate only attributes of tuple instead to __getattr__
(cherry picked from commit 72c359912d36705a94fca8b63d80451905a14ae4)

Co-authored-by: blhsing <github@ydooby.com>
Lib/unittest/mock.py
Lib/unittest/test/testmock/testhelpers.py
Misc/NEWS.d/next/Library/2019-08-28-21-40-12.bpo-37972.kP-n4L.rst [new file with mode: 0644]