aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/qqmlproperty
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qml/qqmlproperty')
-rw-r--r--tests/auto/qml/qqmlproperty/data/invalidBinding.qml2
-rw-r--r--tests/auto/qml/qqmlproperty/tst_qqmlproperty.cpp4
2 files changed, 6 insertions, 0 deletions
diff --git a/tests/auto/qml/qqmlproperty/data/invalidBinding.qml b/tests/auto/qml/qqmlproperty/data/invalidBinding.qml
index 35dacf1619..e2bb1d172d 100644
--- a/tests/auto/qml/qqmlproperty/data/invalidBinding.qml
+++ b/tests/auto/qml/qqmlproperty/data/invalidBinding.qml
@@ -10,5 +10,7 @@ Item {
Text {
id: myText
+
+ anchors.verticalCenter: parent // invalid binding
}
}
diff --git a/tests/auto/qml/qqmlproperty/tst_qqmlproperty.cpp b/tests/auto/qml/qqmlproperty/tst_qqmlproperty.cpp
index 23f7c3437d..5d7485c68d 100644
--- a/tests/auto/qml/qqmlproperty/tst_qqmlproperty.cpp
+++ b/tests/auto/qml/qqmlproperty/tst_qqmlproperty.cpp
@@ -1736,6 +1736,10 @@ void tst_qqmlproperty::warnOnInvalidBinding()
expectedWarning = testUrl.toString() + QString::fromLatin1(":7:36: Unable to assign QQuickText to QQuickRectangle");
QTest::ignoreMessage(QtWarningMsg, expectedWarning.toLatin1().constData());
+ // V8 error message for invalid binding to anchor
+ expectedWarning = testUrl.toString() + QString::fromLatin1(":14: Unable to assign QQuickItem_QML_7 to QQuickAnchorLine");
+ QTest::ignoreMessage(QtWarningMsg, expectedWarning.toLatin1().constData());
+
QQmlComponent component(&engine, testUrl);
QObject *obj = component.create();
QVERIFY(obj);