[TIP] unit testing wxPython wrapper objects.
Titus Brown
titus at caltech.edu
Thu Mar 8 19:29:25 PST 2007
On Thu, Mar 08, 2007 at 02:54:20PM -0700, Nate Lowrie wrote:
-> Ok, normally I just run acceptance tests with the GUIs because they
-> are too costly to write unit tests for. However, in this instance,
-> half of the framework that I am testing is actually a wrapper for
-> wxPython.
->
-> Would you suggest mocking wx so I can verify an UI widget without
-> having to go through the process of starting an app, blah..., blah...,
-> blah...? Everything that could be pushed out to mixins has and those
-> test fine because they don't subclass anything wx, but there is still
-> several thousand lines of code in classes that subclass wx.
->
-> Any help would be appreciated. I would like to avoid using wx for
-> unit tests to avoid slow test smells if at all possible.
Have you seen this?
http://wiki.wxpython.org/index.cgi/Unit_Testing_with_wxPython
There has been some general discussion on wx unit testing on some blog
somewhere, but this is the best link I can find.
Ahh, here's what I was thinking of:
http://dirtsimple.org/2004/12/mocking-wxpython.html
http://yergler.net/blog/2005/04/14/a-plan-for-gui-testing/
Oh well, perhaps not that useful but at least relevant.
HTH,
--titus
More information about the testing-in-python
mailing list