From 0fdf9042ce36c1dcfed64d1600f1526ac176768d Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Mon, 6 Nov 2023 16:23:35 +0100 Subject: QML: Before processing deep aliases, remove pending bindings We may have additional bindings scheduled for the deep alias, but those are to be overridden by the alias. They should therefore be removed like bindings to target properties of shallow aliases. For QProperty bindings we have to apply a separate trick and set and clear the binding bit in the right places. We don't have access to the actual binding when writing the value, after all. Pick-to: 6.6 6.5 6.2 Fixes: QTBUG-115579 Change-Id: Ia915e59905d7e3185a17c5b6613926264ad9bc6b Reviewed-by: Qt CI Bot Reviewed-by: Fabian Kosmale --- tests/auto/qml/qqmllanguage/tst_qqmllanguage.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'tests/auto/qml/qqmllanguage/tst_qqmllanguage.cpp') diff --git a/tests/auto/qml/qqmllanguage/tst_qqmllanguage.cpp b/tests/auto/qml/qqmllanguage/tst_qqmllanguage.cpp index f6b4b2f9b8..a9c508c73d 100644 --- a/tests/auto/qml/qqmllanguage/tst_qqmllanguage.cpp +++ b/tests/auto/qml/qqmllanguage/tst_qqmllanguage.cpp @@ -8411,15 +8411,11 @@ void tst_qqmllanguage::deepAliasOnICOrReadonly() QScopedPointer o(c.create()); QVERIFY(!o.isNull()); - // We are mostly testing that it doesn't crash here. The actual bug is fixed separately. - - QEXPECT_FAIL("", "QTBUG-115579 is not fixed yet", Continue); QCOMPARE(o->property("borderColor").toString(), QLatin1String("black")); + QCOMPARE(o->property("borderObjectName").toString(), QLatin1String("theLeaf")); const QVariant var = o->property("borderVarvar"); - QEXPECT_FAIL("", "QTBUG-115579 is not fixed yet", Continue); QCOMPARE(var.metaType(), QMetaType::fromType()); - QEXPECT_FAIL("", "QTBUG-115579 is not fixed yet", Continue); QCOMPARE(var.toString(), QLatin1String("mauve")); QQmlComponent c2(&engine, testFileUrl("deepAliasOnReadonly.qml")); -- cgit v1.2.3