diff options
author | Mitch Curtis <mitch.curtis@qt.io> | 2016-11-22 14:51:05 +0100 |
---|---|---|
committer | Mitch Curtis <mitch.curtis@qt.io> | 2016-11-22 15:00:11 +0000 |
commit | 261e84c3e333574b300ea0b09f87fccc88c4a0ea (patch) | |
tree | c27a0822ea8838ede93357412af4492de9e72ad9 /tests/auto/controls/data/tst_tumbler.qml | |
parent | 08ba34d6a8cf7e7ab21ce51ca6aa7d812d035a67 (diff) |
Use tryVerify() instead of wait() where possible
This may help with the flaky tst_tooltip test, and makes
tst_tumbler a little bit cleaner.
Task-number: QTBUG-57258
Change-Id: Ida987fb9d60392aba4142e4711131aded56d425d
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
Diffstat (limited to 'tests/auto/controls/data/tst_tumbler.qml')
-rw-r--r-- | tests/auto/controls/data/tst_tumbler.qml | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/tests/auto/controls/data/tst_tumbler.qml b/tests/auto/controls/data/tst_tumbler.qml index b3230ca4..01d5cdee 100644 --- a/tests/auto/controls/data/tst_tumbler.qml +++ b/tests/auto/controls/data/tst_tumbler.qml @@ -83,16 +83,10 @@ TestCase { } function cleanup() { - var destroyed = false; - cleanupItem.Component.destruction.connect(function() { destroyed = true; }); - cleanupItem.destroy(); - // Waiting until it's deleted before continuing makes debugging // test failures much easier, because there aren't unrelated items hanging around. - // TODO: Replace with tryVerify(!tumbler) in 5.8. - while (!destroyed) - wait(0) + tryVerify(function() { return !tumbler; }); } function createTumbler(args) { |