summaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qdeclarativeecmascript/data/propertyAssignmentErrors.qml
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/declarative/qdeclarativeecmascript/data/propertyAssignmentErrors.qml')
-rw-r--r--tests/auto/declarative/qdeclarativeecmascript/data/propertyAssignmentErrors.qml22
1 files changed, 22 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativeecmascript/data/propertyAssignmentErrors.qml b/tests/auto/declarative/qdeclarativeecmascript/data/propertyAssignmentErrors.qml
new file mode 100644
index 00000000..a778dcc8
--- /dev/null
+++ b/tests/auto/declarative/qdeclarativeecmascript/data/propertyAssignmentErrors.qml
@@ -0,0 +1,22 @@
+import QtQuick 1.0
+
+QtObject {
+ id: root
+
+ property int a
+ property variant b
+
+ Component.onCompleted: {
+ try {
+ root.a = undefined;
+ } catch(e) {
+ console.log (e.fileName + ":" + e.lineNumber + ":" + e);
+ }
+
+ try {
+ root.a = "Hello";
+ } catch(e) {
+ console.log (e.fileName + ":" + e.lineNumber + ":" + e);
+ }
+ }
+}