From 45537009a8a3f8e855c1adf0208084849b6dc9c4 Mon Sep 17 00:00:00 2001 From: Maximilian Goldstein Date: Wed, 6 May 2020 13:21:21 +0200 Subject: Fix qmllint crash Fixes: QTBUG-83915 Change-Id: I26731ebcec6be46602b6acc7562c65b1c9f3e43a Reviewed-by: Fabian Kosmale --- tests/auto/qml/qmllint/data/crashConnections.qml | 5 +++++ tests/auto/qml/qmllint/tst_qmllint.cpp | 4 ++++ 2 files changed, 9 insertions(+) create mode 100644 tests/auto/qml/qmllint/data/crashConnections.qml (limited to 'tests/auto/qml') diff --git a/tests/auto/qml/qmllint/data/crashConnections.qml b/tests/auto/qml/qmllint/data/crashConnections.qml new file mode 100644 index 0000000000..cac50c84bd --- /dev/null +++ b/tests/auto/qml/qmllint/data/crashConnections.qml @@ -0,0 +1,5 @@ +import QtQuick 2.0 + +Connections { + target: FirstRunDialog +} \ No newline at end of file diff --git a/tests/auto/qml/qmllint/tst_qmllint.cpp b/tests/auto/qml/qmllint/tst_qmllint.cpp index 0f6fac4ddf..bdb5cf37c0 100644 --- a/tests/auto/qml/qmllint/tst_qmllint.cpp +++ b/tests/auto/qml/qmllint/tst_qmllint.cpp @@ -107,6 +107,10 @@ void TestQmllint::testUnqualified_data() QTest::newRow("CatchStatement") << QStringLiteral("CatchStatement.qml") << QStringLiteral("err") << 6 << 21; QTest::newRow("NonSpuriousParent") << QStringLiteral("nonSpuriousParentWarning.qml") << QStringLiteral("property int x: .parent.x") << 6 << 25; + + QTest::newRow("crashConnections") + << QStringLiteral("crashConnections.qml") + << QStringLiteral("target: FirstRunDialog") << 4 << 13; } void TestQmllint::testUnknownCausesFail() -- cgit v1.2.3