summaryrefslogtreecommitdiffstats
path: root/tests/auto
diff options
context:
space:
mode:
authorAaron Kennedy <aaron.kennedy@nokia.com>2009-10-27 01:41:49 (GMT)
committerAaron Kennedy <aaron.kennedy@nokia.com>2009-10-27 01:41:49 (GMT)
commit809244977033abf2bd934244c9b88b39d8ba1f8a (patch)
treebdba2da7cf3d2ab2181f816d6f8f97f11e8b07a4 /tests/auto
parentb1a5b6c40c6c76d44d9afc24c6cddf1d2abf7b29 (diff)
downloadQt-809244977033abf2bd934244c9b88b39d8ba1f8a.zip
Qt-809244977033abf2bd934244c9b88b39d8ba1f8a.tar.gz
Qt-809244977033abf2bd934244c9b88b39d8ba1f8a.tar.bz2
Error when a QVariant property is used as a grouped property
This crashed as the metatype of QVariant is -1.
Diffstat (limited to 'tests/auto')
-rw-r--r--tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.errors.txt1
-rw-r--r--tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.qml6
-rw-r--r--tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.errors.txt1
-rw-r--r--tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.qml7
-rw-r--r--tests/auto/declarative/qmllanguage/tst_qmllanguage.cpp7
5 files changed, 20 insertions, 2 deletions
diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.errors.txt
new file mode 100644
index 0000000..7c00ce4
--- /dev/null
+++ b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.errors.txt
@@ -0,0 +1 @@
+5:5:Invalid property access
diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.qml b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.qml
new file mode 100644
index 0000000..5e95c48
--- /dev/null
+++ b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.qml
@@ -0,0 +1,6 @@
+import Qt 4.6
+
+Object {
+ property var o;
+ o.blah: 10
+}
diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.errors.txt
new file mode 100644
index 0000000..7c00ce4
--- /dev/null
+++ b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.errors.txt
@@ -0,0 +1 @@
+5:5:Invalid property access
diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.qml b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.qml
new file mode 100644
index 0000000..b11d34c
--- /dev/null
+++ b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.qml
@@ -0,0 +1,7 @@
+import Qt 4.6
+
+Object {
+ property int o;
+ o.blah: 10
+}
+
diff --git a/tests/auto/declarative/qmllanguage/tst_qmllanguage.cpp b/tests/auto/declarative/qmllanguage/tst_qmllanguage.cpp
index d51bbcc..4bc02c0 100644
--- a/tests/auto/declarative/qmllanguage/tst_qmllanguage.cpp
+++ b/tests/auto/declarative/qmllanguage/tst_qmllanguage.cpp
@@ -180,7 +180,6 @@ void tst_qmllanguage::errors_data()
QTest::newRow("invalidID.5") << "invalidID.5.qml" << "invalidID.5.errors.txt" << false;
QTest::newRow("invalidID.6") << "invalidID.6.qml" << "invalidID.6.errors.txt" << false;
-
QTest::newRow("unsupportedProperty") << "unsupportedProperty.qml" << "unsupportedProperty.errors.txt" << false;
QTest::newRow("nullDotProperty") << "nullDotProperty.qml" << "nullDotProperty.errors.txt" << true;
QTest::newRow("fakeDotProperty") << "fakeDotProperty.qml" << "fakeDotProperty.errors.txt" << false;
@@ -191,12 +190,16 @@ void tst_qmllanguage::errors_data()
QTest::newRow("failingComponent") << "failingComponentTest.qml" << "failingComponent.errors.txt" << false;
QTest::newRow("missingSignal") << "missingSignal.qml" << "missingSignal.errors.txt" << false;
QTest::newRow("finalOverride") << "finalOverride.qml" << "finalOverride.errors.txt" << false;
+ QTest::newRow("customParserIdNotAllowed") << "customParserIdNotAllowed.qml" << "customParserIdNotAllowed.errors.txt" << false;
+ QTest::newRow("invalidGroupedProperty.1") << "invalidGroupedProperty.1.qml" << "invalidGroupedProperty.1.errors.txt" << false;
+ QTest::newRow("invalidGroupedProperty.2") << "invalidGroupedProperty.2.qml" << "invalidGroupedProperty.2.errors.txt" << false;
QTest::newRow("importNamespaceConflict") << "importNamespaceConflict.qml" << "importNamespaceConflict.errors.txt" << false;
QTest::newRow("importVersionMissing (builtin)") << "importVersionMissingBuiltIn.qml" << "importVersionMissingBuiltIn.errors.txt" << false;
QTest::newRow("importVersionMissing (installed)") << "importVersionMissingInstalled.qml" << "importVersionMissingInstalled.errors.txt" << false;
- QTest::newRow("customParserIdNotAllowed") << "customParserIdNotAllowed.qml" << "customParserIdNotAllowed.errors.txt" << false;
+
+
}
void tst_qmllanguage::errors()