[TIP] Mock 0.8rc2 and a couple of mock recipes
Michael Foord
michael at voidspace.org.uk
Fri Jan 13 12:54:22 PST 2012
Hey all,
I did a new release of mock 0.8, fixing the issue reported here by Tom Davis and an api change to create_autospec to make it consistent with other parts of the mock api.
Details of mock 0.8rc2 here:
http://www.voidspace.org.uk/python/weblog/arch_d7_2012_01_07.shtml#e1230
A recipe for a DeletingMock, where deleting attributes causes future access to those attributes to raise an AttributeError:
http://www.voidspace.org.uk/python/weblog/arch_d7_2012_01_07.shtml#e1231
A recipe for super simple mocking of open as a context manager:
http://www.voidspace.org.uk/python/weblog/arch_d7_2012_01_07.shtml#e1232
All the best,
Michael Foord
--
http://www.voidspace.org.uk/
May you do good and not evil
May you find forgiveness for yourself and forgive others
May you share freely, never taking more than you give.
-- the sqlite blessing
http://www.sqlite.org/different.html
More information about the testing-in-python
mailing list