diff options
| author | Linus Jahn <lnj@kaidan.im> | 2022-09-11 01:59:14 +0200 |
|---|---|---|
| committer | Linus Jahn <lnj@kaidan.im> | 2022-09-12 23:06:16 +0200 |
| commit | 0c1311a8181b4b6bc7a40e622bc9811898569827 (patch) | |
| tree | cbe1448f6d6fa871eaa7156441d1b6d41f60ec5f | |
| parent | 0c4703e923280081280f366be3daec0ccdc8dc8f (diff) | |
| download | qxmpp-0c1311a8181b4b6bc7a40e622bc9811898569827.tar.gz | |
tests: util: wait: Check whether spy.wait() succeeded
| -rw-r--r-- | tests/util.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/util.h b/tests/util.h index 34cd0d6e..4f193d6a 100644 --- a/tests/util.h +++ b/tests/util.h @@ -100,7 +100,7 @@ T wait(const QFuture<T> &future) auto watcher = std::make_unique<QFutureWatcher<T>>(); QSignalSpy spy(watcher.get(), &QFutureWatcherBase::finished); watcher->setFuture(future); - spy.wait(); + [&]() { QVERIFY(spy.wait()); }(); if constexpr (!std::is_same_v<T, void>) { return future.result(); } |
