[PyKDE] Support for the unitest framework of Qt

Phil Thompson phil at riverbankcomputing.co.uk
Sun Sep 24 00:40:57 BST 2006


On Friday 22 September 2006 1:37 pm, Giovanni Bajo wrote:
> Phil Thompson wrote:
> >> Is there planned any support for the Qt Uni Testing Framework?
> >
> > No plans. It seems to use templates for some things (addColumn())
> > which makes it a real pain. Is there a useful subset you can identify?
>
> In my opinion, the testing *framework* itself is not very useful: we have
> pleny of them in Python already (unittest, etc.) and in an average PyQt
> program there will be other tests not related to Qt. I guess an average
> PyQt program with tests will use a Python framework for tests.
>
> What is very useful, instead, are the functions to *implement* tests, like
> keyClick(), mouseMove() and similar functions. I'll prepared a short list
> of functions/macros/enum in the QTest namespace which I believe would be
> very useful in PyQt:
>
> enum KeyAction
> enum MouseAction
> keyClick()
> keyClicks()
> keyEvent()
> keyPress()
> keyRelease()
> mouseClick()
> mouseDClick()
> mouseMove()
> mousePress()
> mouseRelease()
> qSleep()
> qWait()
>
> Anything else, like the QTEST/QVERIFY family of macros, are part of the
> framework, which I personally don't plan to ever use in a PyQt application
> anyway.

Thanks - it's so much easier when somebody provides a specification.

It will be in tonight's snapshot.

Now I hope somebody will produce a nice GUI based user recording and testing 
plugin for eric4 ;)

Phil




More information about the PyQt mailing list