summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJanne Anttila <janne.anttila@digia.com>2009-09-30 12:56:43 (GMT)
committerJanne Anttila <janne.anttila@digia.com>2009-09-30 12:57:40 (GMT)
commitaf1e344ac6046640ddb728f6017b3181469c241d (patch)
treef708fc793c9cdfb348c9cc35d4b32839a8898a92
parent28be44a363468f1d3cf0a041c3daf88893820edd (diff)
downloadQt-af1e344ac6046640ddb728f6017b3181469c241d.zip
Qt-af1e344ac6046640ddb728f6017b3181469c241d.tar.gz
Qt-af1e344ac6046640ddb728f6017b3181469c241d.tar.bz2
Making tst_QListWidget::closePersistentEditor work for Symbian.
The persistent editor was not closed in time, as events from Symbian app start up had not had time to be flushed through. The addition of a 1s QTest::qWait gives plenty of time for the app to settle. Probably the better fix would be to add piece of code to testlib which would empty the event queue before executing each test case. However this was seen as an risky solution. Reviewed-by: mread
-rw-r--r--tests/auto/qlistwidget/tst_qlistwidget.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/auto/qlistwidget/tst_qlistwidget.cpp b/tests/auto/qlistwidget/tst_qlistwidget.cpp
index d31b07f..e825c8f 100644
--- a/tests/auto/qlistwidget/tst_qlistwidget.cpp
+++ b/tests/auto/qlistwidget/tst_qlistwidget.cpp
@@ -302,6 +302,11 @@ void tst_QListWidget::openPersistentEditor()
void tst_QListWidget::closePersistentEditor()
{
+#if defined(Q_OS_SYMBIAN)
+ //give the Symbian app start event queue time to clear
+ QTest::qWait(1000);
+#endif
+
// Boundry checking
int childCount = testWidget->viewport()->children().count();
testWidget->closePersistentEditor(0);