Message185326
| Author |
michael.foord |
| Recipients |
Julian, brett.cannon, chris.jerdonek, daniel.urban, eric.araujo, ezio.melotti, michael.foord, pablomouzo, r.david.murray |
| Date |
2013年03月27日.12:25:26 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1364387127.14.0.621020485388.issue11664@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
Yes this is still relevant and needs doing (and is easy).
The implementation should be similar to:
def patch(self, *args, **kwargs):
# lazy import
from unittest.mock import patch
p = patch(*args, **kwargs)
result = p.start()
self.addCleanup(p.stop)
return result
Plus tests and documentation. |
|