diff options
author | Fabian Kosmale <fabian.kosmale@qt.io> | 2020-11-02 11:27:43 +0100 |
---|---|---|
committer | Fabian Kosmale <fabian.kosmale@qt.io> | 2020-11-03 09:48:15 +0100 |
commit | 67beaf3a1fa6c4b43c106fd069f886d51401fcbc (patch) | |
tree | b3ea392bba9d47e7646f7609dc5f31d02a04a818 | |
parent | b19e9daf46afd996818fa625abb705bf8d4ca893 (diff) |
tst_qqmlbinding: Do not leak component
Change-Id: If562268b29fae9b0e0254719ce8d4489cfab2943
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Andrei Golubev <andrei.golubev@qt.io>
-rw-r--r-- | tests/auto/qml/qqmlbinding/tst_qqmlbinding.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/auto/qml/qqmlbinding/tst_qqmlbinding.cpp b/tests/auto/qml/qqmlbinding/tst_qqmlbinding.cpp index b3e6ffd79e..afb42453d4 100644 --- a/tests/auto/qml/qqmlbinding/tst_qqmlbinding.cpp +++ b/tests/auto/qml/qqmlbinding/tst_qqmlbinding.cpp @@ -380,7 +380,8 @@ void tst_qqmlbinding::bindToQmlComponent() { QQmlEngine engine; QQmlComponent c(&engine, testFileUrl("bindToQMLComponent.qml")); - QVERIFY(c.create()); + QScopedPointer<QObject> root {c.create()}; + QVERIFY(root); } // QTBUG-78943 |