Author Darragh Bailey
Recipients Darragh Bailey
Date 2015-11-10.17:02:38
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
Both unittest.mock and the backported release for earlier pythons don't appear to support mocking of dictionary objects.

Specifically I'm expecting that any of the methods used to test for membership, or get items from a mock object wrapping a dictionary should succeed. However it appears that MagicMock doesn't appear to support this.

Attached file shows an attempt to use different methods with a wrapped dictionary object where only the '.get()' method appears to work as expected.
Date User Action Args
2015-11-10 17:02:38Darragh Baileysetrecipients: + Darragh Bailey
2015-11-10 17:02:38Darragh Baileysetmessageid: <>
2015-11-10 17:02:38Darragh Baileylinkissue25597 messages
2015-11-10 17:02:38Darragh Baileycreate