35 CTestWorker::CTestWorker(QObject *parent) : QObject(parent)
40 void CTestWorker::singleShot()
43 CEventLoop::processEventsFor(0);
44 QVERIFY2(future.isFinished(),
"Future is finished after slot has returned");
45 QVERIFY2(future.result() == 123,
"Future provides access to slot's return value");
53 #include "testworker.moc"
Aviation classes basic tests.
Free functions in swift::misc.
auto singleShot(int msec, QObject *target, F &&task)
Starts a single-shot timer which will call a task in the thread of the given object when it times out...
SWIFTTEST_APPLESS_MAIN(MiscTest::CTestWorker)
main