7#include <QtCore/qbytearray.h>
8#include <QtCore/qlist.h>
9#include <QtCore/qmetaobject.h>
10#include <QtTest/qtesteventloop.h>
11#include <QtCore/qvariant.h>
12#include <QtCore/qmutex.h>
28 std::unique_ptr<QSignalSpyPrivate> d_ptr;
33 template <
typename Po
interToMemberFunction>
36 template <
typename Func>
44 bool isValid() const noexcept {
return d_ptr !=
nullptr; }
48 {
return wait(std::chrono::milliseconds{
timeout}); }
50 Q_TESTLIB_EXPORT
bool wait(std::chrono::milliseconds
timeout = std::chrono::seconds{5});
53 Q_TESTLIB_EXPORT
explicit QSignalSpy(ObjectSignal os);
56 Q_TESTLIB_EXPORT
static ObjectSignal verify(
const QObject *
obj,
const char *aSignal);
58 Q_TESTLIB_EXPORT
void appendArgs(
void **
a);
63 const QList<int>
args;
66 bool m_waiting =
false;
QSignalSpy(const typename QtPrivate::FunctionPointer< Func >::Object *obj, Func signal0)
QSignalSpy(const QObject *obj, const char *aSignal)
Constructs a new QSignalSpy that listens for emissions of the signal from the QObject object.
QByteArray signal() const
Returns the normalized signal the spy is currently listening to.
Q_TESTLIB_EXPORT ~QSignalSpy()
Destructor.
bool isValid() const noexcept
Returns true if the signal spy listens to a valid signal, otherwise false.
QSignalSpy(const QObject *obj, QMetaMethod signal)
Combined button and popup list for selecting options.
GLboolean GLboolean GLboolean GLboolean a
[7]
GLbitfield GLuint64 timeout
[4]