Author jcrotts
Recipients docs@python, jcrotts
Date 2018-05-31.18:35:34
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1527791734.24.0.682650639539.issue33722@psf.upfronthosting.co.za>
In-reply-to
Content
The examples on using mock_open only include instances where objects are mocked in the REPL, so '__main__'.open is replaced. Commonly objects are mocked for use in other test modules, so builtins.open would be used instead.

A note about this in the documentation would be useful not familiar with python internals. I'm happy to do a PR for it.
History
Date User Action Args
2018-05-31 18:35:34jcrottssetrecipients: + jcrotts, docs@python
2018-05-31 18:35:34jcrottssetmessageid: <1527791734.24.0.682650639539.issue33722@psf.upfronthosting.co.za>
2018-05-31 18:35:34jcrottslinkissue33722 messages
2018-05-31 18:35:34jcrottscreate