diff options
| author | Frank Reininghaus <[email protected]> | 2010-11-29 21:24:53 +0000 |
|---|---|---|
| committer | Frank Reininghaus <[email protected]> | 2010-11-29 21:24:53 +0000 |
| commit | f45966d9c3f7ac513d87eef024fb328029e89ba5 (patch) | |
| tree | a44c464a5c8699b45efe41400fbc461b2c057d92 /src/tests | |
| parent | bdcca2b903610699932656637ca95bc6969e7c45 (diff) | |
Use kWaitForSignal to wait until the view has finished reloading. I've
also added a timeout such that the tests fail rather than hang if the
file kioslave dies (which happens sometimes according to some test
logs on cdash.org).
svn path=/trunk/KDE/kdebase/apps/; revision=1202159
Diffstat (limited to 'src/tests')
| -rw-r--r-- | src/tests/testbase.cpp | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/tests/testbase.cpp b/src/tests/testbase.cpp index 0fd48cbd2..2161c9314 100644 --- a/src/tests/testbase.cpp +++ b/src/tests/testbase.cpp @@ -66,13 +66,8 @@ QAbstractItemView* TestBase::itemView () const void TestBase::reloadViewAndWait() { - kDebug() << "Reloading view and waiting for the finishedPathLoading(const KUrl&) signal..."; - QSignalSpy finished(m_view, SIGNAL(finishedPathLoading(const KUrl&))); m_view->reload(); - while (finished.count() != 1) { - QTest::qWait(50); - } - kDebug() << "...signal received, continuing"; + QVERIFY(QTest::kWaitForSignal(m_view, SIGNAL(finishedPathLoading(const KUrl&)), 5000)); } KUrl TestBase::testDirUrl() const |
