From 48b41aadb9fe775d67c404ca79db5deda1e4bbbd Mon Sep 17 00:00:00 2001 From: Ivailo Monev Date: Sat, 1 Feb 2020 23:10:36 +0000 Subject: [PATCH] kfile: fix race condition in KDirOperatorTest::testBug187066() test Signed-off-by: Ivailo Monev --- kfile/tests/kdiroperatortest.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/kfile/tests/kdiroperatortest.cpp b/kfile/tests/kdiroperatortest.cpp index 429fc304..8d0a1a63 100644 --- a/kfile/tests/kdiroperatortest.cpp +++ b/kfile/tests/kdiroperatortest.cpp @@ -84,10 +84,12 @@ private Q_SLOTS: KDirOperator dirOp(kFileDirUrl); dirOp.setView(KFile::DetailTree); - QTest::kWaitForSignal(dirOp.dirLister(), SIGNAL(completed())); + QTest::qWait(3000); + QVERIFY(dirOp.dirLister()->isFinished()); dirOp.setCurrentItem("file:///"); dirOp.setCurrentItem(KDESRCDIR "kdiroperatortest.cpp"); - QTest::kWaitForSignal(dirOp.dirLister(), SIGNAL(completed())); + QTest::qWait(3000); + QVERIFY(dirOp.dirLister()->isFinished()); } };