Results 1 to 4 of 4

Thread: Howto test classes laying in a project with template = app?

  1. #1
    Join Date
    Dec 2010
    Posts
    4
    Thanks
    2
    Qt products
    Qt4
    Platforms
    Windows

    Default Howto test classes laying in a project with template = app?

    Hello Community,

    I want to test a class in a test project which is laying in a project with ".pro" file
    Qt Code:
    1. TEMPLATE = app
    To copy to clipboard, switch view to plain text mode 

    How can I test those classes?

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Howto test classes laying in a project with template = app?

    Write a test program and add the file to your test project.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


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

    70thCommander (7th March 2011)

  4. #3
    Join Date
    Dec 2010
    Posts
    4
    Thanks
    2
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Howto test classes laying in a project with template = app?

    How can I reference those project if the result is an exe file?
    (Sorry, want to reply on your answer!)

  5. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Howto test classes laying in a project with template = app?

    You reference files, not projects.
    qmake Code:
    1. SOURCES += relative/path/to/directory/name-of-file.cpp
    To copy to clipboard, switch view to plain text mode 
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


Similar Threads

  1. problem with using template classes
    By arbi in forum General Programming
    Replies: 4
    Last Post: 1st September 2010, 13:29
  2. How do you run multiple test classes?
    By jeffadams78 in forum Qt Programming
    Replies: 3
    Last Post: 2nd April 2009, 18:39
  3. Replies: 0
    Last Post: 2nd February 2009, 14:24
  4. Template classes and abstraction of type
    By Raistlin in forum General Programming
    Replies: 15
    Last Post: 1st April 2008, 10:18
  5. signal/slots in template classes
    By killkolor in forum Qt Programming
    Replies: 2
    Last Post: 6th December 2006, 18:28

Tags for this Thread

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.