This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author cjw296
Recipients Anvil, cjw296, mariocj89, michael.foord, xtreak
Date 2020-01-24.08:26:24
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1579854384.23.0.872716462256.issue37669@roundup.psfhosted.org>
In-reply-to
Content
I'm not sure I like the API feel after this change: two parameters that can't be used at the same time.

As Karthikeyan points out, this can be achieved using side_effect. Personally, I'd prefer a PR that adds a unit test showing that this approach works, and an example included in the docs as suggested above.

Also, be aware that there can be better options for mocking files. https://github.com/jmcgeheeiv/pyfakefs/ and https://docs.pytest.org/en/latest/tmpdir.html would be my recommendation.
History
Date User Action Args
2020-01-24 08:26:24cjw296setrecipients: + cjw296, michael.foord, mariocj89, xtreak, Anvil
2020-01-24 08:26:24cjw296setmessageid: <1579854384.23.0.872716462256.issue37669@roundup.psfhosted.org>
2020-01-24 08:26:24cjw296linkissue37669 messages
2020-01-24 08:26:24cjw296create