Improve reliability of propertyVarOwnership test
authorSimon Hausmann <simon.hausmann@digia.com>
Tue, 27 Aug 2013 10:11:18 +0000 (12:11 +0200)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Tue, 27 Aug 2013 11:55:22 +0000 (13:55 +0200)
commitfc9199e4dbce55b011f66c36391e6c6aa08bd318
tree990b1bad59f9c46163bee2ca6ee3313ebecb31de
parentc317b2e46527b14c8fd30e0d198a9ee134cee123
Improve reliability of propertyVarOwnership test

In the last expect-to-collect-a-QObject test, avoid calling gc() from within
JavaScript and call it from C++ instead with zap stacking. That reduces the
probability of finding an old reference on the stack that would keep the
object alive.

Change-Id: Ia9c66dd188f31264a70ad4dbd20356d16aa7a057
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
tests/auto/qml/qqmlecmascript/data/propertyVarOwnership.5.qml
tests/auto/qml/qqmlecmascript/tst_qqmlecmascript.cpp