diff options
5 files changed, 11 insertions, 1 deletions
diff --git a/tests/auto/declarative/qmlparser/tst_qmlparser.cpp b/tests/auto/declarative/qmlparser/tst_qmlparser.cpp index a3b94db..7b6d7aa 100644 --- a/tests/auto/declarative/qmlparser/tst_qmlparser.cpp +++ b/tests/auto/declarative/qmlparser/tst_qmlparser.cpp @@ -399,7 +399,8 @@ void tst_qmlparser::errors_data() QTest::newRow("wrongType (int for datetime)") << "wrongType.10.txt" << "wrongType.10.errors.txt" << false; QTest::newRow("wrongType (string for point)") << "wrongType.11.txt" << "wrongType.11.errors.txt" << false; QTest::newRow("wrongType (color for size)") << "wrongType.12.txt" << "wrongType.12.errors.txt" << false; - + QTest::newRow("wrongType (number string for int)") << "wrongType.13.txt" << "wrongType.13.errors.txt" << false; + QTest::newRow("wrongType (int for string)") << "wrongType.14.txt" << "wrongType.14.errors.txt" << false; QTest::newRow("nonExistantProperty.1") << "readOnly.1.txt" << "readOnly.1.errors.txt" << false; QTest::newRow("nonExistantProperty.2") << "readOnly.2.txt" << "readOnly.2.errors.txt" << true; diff --git a/tests/auto/declarative/qmlparser/wrongType.13.errors.txt b/tests/auto/declarative/qmlparser/wrongType.13.errors.txt new file mode 100644 index 0000000..7ff4bf3 --- /dev/null +++ b/tests/auto/declarative/qmlparser/wrongType.13.errors.txt @@ -0,0 +1 @@ +2:12:Cannot assign value "12" to property value diff --git a/tests/auto/declarative/qmlparser/wrongType.13.txt b/tests/auto/declarative/qmlparser/wrongType.13.txt new file mode 100644 index 0000000..075ec03 --- /dev/null +++ b/tests/auto/declarative/qmlparser/wrongType.13.txt @@ -0,0 +1,3 @@ +MyQmlObject { + value: "12" +} diff --git a/tests/auto/declarative/qmlparser/wrongType.14.errors.txt b/tests/auto/declarative/qmlparser/wrongType.14.errors.txt new file mode 100644 index 0000000..ec41e01 --- /dev/null +++ b/tests/auto/declarative/qmlparser/wrongType.14.errors.txt @@ -0,0 +1 @@ +2:23:Cannot assign value 10 to property stringProperty diff --git a/tests/auto/declarative/qmlparser/wrongType.14.txt b/tests/auto/declarative/qmlparser/wrongType.14.txt new file mode 100644 index 0000000..3d39c87 --- /dev/null +++ b/tests/auto/declarative/qmlparser/wrongType.14.txt @@ -0,0 +1,4 @@ +MyTypeObject { + stringProperty: 10 +} + |