diff options
Diffstat (limited to 'tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp')
| -rw-r--r-- | tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp b/tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp index 5780862b47..90fd5f391c 100644 --- a/tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp +++ b/tests/auto/qml/qmlcppcodegen/tst_qmlcppcodegen.cpp @@ -1104,7 +1104,8 @@ void tst_QmlCppCodegen::callObjectLookupOnNull() qPrintable(urlString + u":5:5: TypeError: Cannot call method 'getName' of null")); o->setProperty("person", QVariant::fromValue<Person *>(nullptr)); - QCOMPARE(o->objectName(), QString()); + // Since the binding threw an exception, we expect the value _not_ to get updated. + QCOMPARE(o->objectName(), u"horst"_s); } void tst_QmlCppCodegen::callWithSpread() |
