Results 1 to 3 of 3

Thread: UNit Testing

  1. #1
    Join Date
    Feb 2011
    Posts
    12
    Thanks
    1
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default UNit Testing

    Dear All,
    QtSampleUnitTesting.zip

    I've written a sample unit testing application.

    There is a push button. On clicking this button QMessageBox should be opened. Can any body check my application and tell if the code is write or wron. This app us target for Linux (Ubuntu).

  2. #2
    Join Date
    Aug 2009
    Location
    coimbatore,India
    Posts
    314
    Thanks
    37
    Thanked 47 Times in 43 Posts
    Qt products
    Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: UNit Testing

    hi Qt_Kid,
    add Q_OBJECT in CSample. and in testCase1 why you are using QTest::mouseRelease.
    It should be QTest::mouseClick

    This should work.
    hope it helps,
    Bala

  3. The following user says thank you to BalaQT for this useful post:

    Qt_Kid (3rd May 2011)

  4. #3
    Join Date
    Feb 2011
    Posts
    12
    Thanks
    1
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: UNit Testing

    Thank you very much. Its wrking nw

Similar Threads

  1. How to do Unit testing
    By Qt_Kid in forum Newbie
    Replies: 4
    Last Post: 30th March 2011, 00:49
  2. using QT unit testing with CMake
    By carpevitam in forum General Discussion
    Replies: 2
    Last Post: 3rd January 2011, 00:20
  3. Qt unit testing
    By chandan in forum Newbie
    Replies: 3
    Last Post: 13th July 2010, 19:20
  4. Unit testing Gui applications
    By yop in forum Qt Programming
    Replies: 0
    Last Post: 17th May 2009, 15:40
  5. QTest Unit Testing
    By bothapn in forum Qt Programming
    Replies: 1
    Last Post: 16th July 2006, 22:11

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.