aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/qquickworkerscript/data
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qml/qquickworkerscript/data')
-rw-r--r--tests/auto/qml/qquickworkerscript/data/script_function.js8
-rw-r--r--tests/auto/qml/qquickworkerscript/data/script_global.js5
-rw-r--r--tests/auto/qml/qquickworkerscript/data/script_global2.js6
-rw-r--r--tests/auto/qml/qquickworkerscript/data/script_var.js6
-rw-r--r--tests/auto/qml/qquickworkerscript/data/worker_function.qml5
-rw-r--r--tests/auto/qml/qquickworkerscript/data/worker_global.qml5
-rw-r--r--tests/auto/qml/qquickworkerscript/data/worker_global2.qml5
-rw-r--r--tests/auto/qml/qquickworkerscript/data/worker_var.qml5
8 files changed, 45 insertions, 0 deletions
diff --git a/tests/auto/qml/qquickworkerscript/data/script_function.js b/tests/auto/qml/qquickworkerscript/data/script_function.js
new file mode 100644
index 0000000000..c0391dd0ae
--- /dev/null
+++ b/tests/auto/qml/qquickworkerscript/data/script_function.js
@@ -0,0 +1,8 @@
+function func() {
+ return "World"
+}
+
+WorkerScript.onMessage = function(msg) {
+ WorkerScript.sendMessage(msg + " " + func())
+}
+
diff --git a/tests/auto/qml/qquickworkerscript/data/script_global.js b/tests/auto/qml/qquickworkerscript/data/script_global.js
new file mode 100644
index 0000000000..cce4f2ceca
--- /dev/null
+++ b/tests/auto/qml/qquickworkerscript/data/script_global.js
@@ -0,0 +1,5 @@
+WorkerScript.onMessage = function(msg) {
+ world = "World"
+ WorkerScript.sendMessage(msg + " " + world)
+}
+
diff --git a/tests/auto/qml/qquickworkerscript/data/script_global2.js b/tests/auto/qml/qquickworkerscript/data/script_global2.js
new file mode 100644
index 0000000000..0867f7ee76
--- /dev/null
+++ b/tests/auto/qml/qquickworkerscript/data/script_global2.js
@@ -0,0 +1,6 @@
+world = "World"
+
+WorkerScript.onMessage = function(msg) {
+ WorkerScript.sendMessage(msg + " " + world)
+}
+
diff --git a/tests/auto/qml/qquickworkerscript/data/script_var.js b/tests/auto/qml/qquickworkerscript/data/script_var.js
new file mode 100644
index 0000000000..77107e8344
--- /dev/null
+++ b/tests/auto/qml/qquickworkerscript/data/script_var.js
@@ -0,0 +1,6 @@
+var world = "World"
+
+WorkerScript.onMessage = function(msg) {
+ WorkerScript.sendMessage(msg + " " + world)
+}
+
diff --git a/tests/auto/qml/qquickworkerscript/data/worker_function.qml b/tests/auto/qml/qquickworkerscript/data/worker_function.qml
new file mode 100644
index 0000000000..f8d01dcfcc
--- /dev/null
+++ b/tests/auto/qml/qquickworkerscript/data/worker_function.qml
@@ -0,0 +1,5 @@
+import QtQuick 2.0
+
+BaseWorker {
+ source: "script_function.js"
+}
diff --git a/tests/auto/qml/qquickworkerscript/data/worker_global.qml b/tests/auto/qml/qquickworkerscript/data/worker_global.qml
new file mode 100644
index 0000000000..546afd2f39
--- /dev/null
+++ b/tests/auto/qml/qquickworkerscript/data/worker_global.qml
@@ -0,0 +1,5 @@
+import QtQuick 2.0
+
+BaseWorker {
+ source: "script_global.js"
+}
diff --git a/tests/auto/qml/qquickworkerscript/data/worker_global2.qml b/tests/auto/qml/qquickworkerscript/data/worker_global2.qml
new file mode 100644
index 0000000000..42cad3852b
--- /dev/null
+++ b/tests/auto/qml/qquickworkerscript/data/worker_global2.qml
@@ -0,0 +1,5 @@
+import QtQuick 2.0
+
+BaseWorker {
+ source: "script_global2.js"
+}
diff --git a/tests/auto/qml/qquickworkerscript/data/worker_var.qml b/tests/auto/qml/qquickworkerscript/data/worker_var.qml
new file mode 100644
index 0000000000..ea6a23cd3e
--- /dev/null
+++ b/tests/auto/qml/qquickworkerscript/data/worker_var.qml
@@ -0,0 +1,5 @@
+import QtQuick 2.0
+
+BaseWorker {
+ source: "script_var.js"
+}