[issue11664] Add patch method to unittest.TestCase

Michael Foord report at bugs.python.org
Wed Sep 19 11:32:06 CEST 2012


Michael Foord added the comment:

It maybe that patch.object is a more natural interface to the small sample of people commenting here, in which case great - that's what it's there for. 

However in common usage patch is used around two orders of magnitude more. I've seen large codebases with hundreds of uses of patch and only a handful of uses of patch.object.

To support the *minor* use case and not the major use case in TestCase would be an inanity.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue11664>
_______________________________________


More information about the Python-bugs-list mailing list