Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8417265
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T01:59:31+00:00 2026-06-10T01:59:31+00:00

Basically I am following the basic example here . My .pro file contains QT

  • 0

Basically I am following the basic example here. My .pro file contains QT += core network qtestlib. [Solved] testlib instead of typo qtestlib

When I include QVERIFY, It get the following linker error:

testwaypointlist.obj:-1: error: LNK2019: unresolved external symbol "bool __cdecl
QTest::qVerify(bool,char const *,char const *,char const *,int)"
(?qVerify@QTest@@YA_N_NPBD11H@Z) referenced in function "private: void __thiscall
TestWaypointList::fillWaypoints(void)" (?fillWaypoints@TestWaypointList@@AAEXXZ)

What files do I miss to link? Without QVERIFY the linker error disappears.

Header file:

#include <QObject>
#include <QtTest/QtTest>
#include "waypointlist.h"

//
// Testing the waypoint list
//
class TestWaypointList : public QObject
{
    Q_OBJECT

private:
    WaypointList _waypointList;
public:
    explicit TestWaypointList(QObject *parent = 0);
private slots:
    void fillWaypoints();
};

cpp:

//
// Fill the waypoint list
//
void TestWaypointList::fillWaypoints()
{
    _waypointList = WaypointList();
    .....

    for (int i=0; i < TESTWPLISTCOUNT; i++) {
        .....
        TestWaypointList::_waypointList.updateOrAppend(id, timeframe);
    }
    QVERIFY(TestWaypointList::_waypointList.count() == 1); // causing the linker error
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T01:59:32+00:00Added an answer on June 10, 2026 at 1:59 am

    In your .pro file, you need to change QT += qtestlib to QT += testlib (note the absence of a “q”).

    Of note, you used to be able to do this: CONFIG += qtestlib, but according to the comment on this page, this is no longer the recommended way of linking to the test library.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Can you provide me a basic iPhone example which has the following; a. It
I am missing something basic, here. Must have forgotten it. But basically, I have
I tried the following: Basically, it should say: If there's no cookie, get lang
My problem can be reduced to basically the following set of entities : I
The following code basically works as expected. However, to be paranoid, I was wondering,
I basically have the following string in the format: A,B,C:D,E,F What I am trying
I basically have the following class: .sf-sub-indicator { background: url(/abcprod/images/arrows-ffffff.png) no-repeat -10px -100px; }
I want to build a bot that basically does the following: Listens to the
Basically I'm querying a table like the following keywordId | keyword 1 abc 1
Basically I have a new client that is after the following functionality from her

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.