aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/qqmlecmascript/data/dynamicDeletion.qml
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qml/qqmlecmascript/data/dynamicDeletion.qml')
-rw-r--r--tests/auto/qml/qqmlecmascript/data/dynamicDeletion.qml20
1 files changed, 20 insertions, 0 deletions
diff --git a/tests/auto/qml/qqmlecmascript/data/dynamicDeletion.qml b/tests/auto/qml/qqmlecmascript/data/dynamicDeletion.qml
new file mode 100644
index 0000000000..f41e5262fd
--- /dev/null
+++ b/tests/auto/qml/qqmlecmascript/data/dynamicDeletion.qml
@@ -0,0 +1,20 @@
+import Qt.test 1.0
+
+MyQmlObject{
+ id: obj
+ objectName: "obj"
+ function create()
+ {
+ obj.objectProperty = Qt.createQmlObject('import Qt.test 1.0; MyQmlObject{objectName:"emptyObject"}', obj);
+ }
+
+ function killOther()
+ {
+ obj.objectProperty.destroy(500);
+ }
+
+ function killMe()
+ {
+ obj.destroy();//Must not segfault
+ }
+}