summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/declarative/qmlecmascript/data/dynamicDeletion.qml2
-rw-r--r--tests/auto/declarative/qmlecmascript/tst_qmlecmascript.cpp8
2 files changed, 7 insertions, 3 deletions
diff --git a/tests/auto/declarative/qmlecmascript/data/dynamicDeletion.qml b/tests/auto/declarative/qmlecmascript/data/dynamicDeletion.qml
index ba87b32..0855b29 100644
--- a/tests/auto/declarative/qmlecmascript/data/dynamicDeletion.qml
+++ b/tests/auto/declarative/qmlecmascript/data/dynamicDeletion.qml
@@ -10,7 +10,7 @@ MyQmlObject{
function killOther()
{
- obj.objectProperty.destroy(100);
+ obj.objectProperty.destroy(500);
}
function killMe()
diff --git a/tests/auto/declarative/qmlecmascript/tst_qmlecmascript.cpp b/tests/auto/declarative/qmlecmascript/tst_qmlecmascript.cpp
index 2182ff4..e5472bb 100644
--- a/tests/auto/declarative/qmlecmascript/tst_qmlecmascript.cpp
+++ b/tests/auto/declarative/qmlecmascript/tst_qmlecmascript.cpp
@@ -849,8 +849,12 @@ void tst_qmlecmascript::dynamicDestruction()
QTest::qWait(0);
QCoreApplication::instance()->processEvents(QEventLoop::DeferredDeletion);
QVERIFY(createdQmlObject);
- QTest::qWait(100);
- QCoreApplication::instance()->processEvents(QEventLoop::DeferredDeletion);
+ for (int ii = 0; createdQmlObject && ii < 10; ++ii) {
+ if (createdQmlObject) {
+ QTest::qWait(100);
+ QCoreApplication::instance()->processEvents(QEventLoop::DeferredDeletion);
+ }
+ }
QVERIFY(!createdQmlObject);
QMetaObject::invokeMethod(object, "killMe");