12 May 2004 04:25
Re: [TFUI] testing Qt code
> dammak rafik wrote: > > table respecting MVC pattern.two for testing GUI how > > I must do?test > > tools for this case?I am developing a kind of unit > > testing (no with > > cppunit) and I like respect this method in GUI > > development. We have been using Qt and CppUnit together with out too many problems. On Tue, 11 May 2004 15:15:58 -0700 (PDT) Phlip <phlipcpp@...> wrote: > Your first question: What is the Qt equivalent of > gtk_main(), and how to not call it? I don't think that there is an equivalent in Qt. The main event loop is generally started by calling the exec() function on QApplication. SInce this is usually called from main() it is easy not to call in the tests.. > The second question: How to optionally call it? Much of the testing of the interface can be done without using the event handling mechanisms of Qt. If it is necessary to test the results of events then QApplication::processEvents() allows all pending events to be processed and then returns control to the test. Regards David(Continue reading)
RSS Feed