diff options
Diffstat (limited to 'tests/auto/qml/qqmlecmascript/data')
5 files changed, 39 insertions, 0 deletions
diff --git a/tests/auto/qml/qqmlecmascript/data/jsimport/importModuleApi.js b/tests/auto/qml/qqmlecmascript/data/jsimport/importModuleApi.js new file mode 100644 index 0000000000..7a4f434665 --- /dev/null +++ b/tests/auto/qml/qqmlecmascript/data/jsimport/importModuleApi.js @@ -0,0 +1,5 @@ +.import Qt.test 1.0 as QObjectModuleApi + +function testFunc() { + return QObjectModuleApi.qobjectTestProperty +} diff --git a/tests/auto/qml/qqmlecmascript/data/jsimport/testImportModuleApi.qml b/tests/auto/qml/qqmlecmascript/data/jsimport/testImportModuleApi.qml new file mode 100644 index 0000000000..b3e545dd7c --- /dev/null +++ b/tests/auto/qml/qqmlecmascript/data/jsimport/testImportModuleApi.qml @@ -0,0 +1,10 @@ +import QtQuick 2.0 +import "importModuleApi.js" as Script + +Item { + property variant testValue: 5 + + Component.onCompleted: { + testValue = Script.testFunc(); + } +} diff --git a/tests/auto/qml/qqmlecmascript/data/rewriteMultiLineStrings_crlf.1.qml b/tests/auto/qml/qqmlecmascript/data/rewriteMultiLineStrings_crlf.1.qml new file mode 100644 index 0000000000..f84ba8c722 --- /dev/null +++ b/tests/auto/qml/qqmlecmascript/data/rewriteMultiLineStrings_crlf.1.qml @@ -0,0 +1,13 @@ +import QtQuick 2.0 + +Rectangle { + id: root + + Component.onCompleted: { + var o = Qt.createQmlObject("import QtQuick 2.0; \ + \ + Item { \ + property bool b: true; \ + }", root, "Instance") + } +} diff --git a/tests/auto/qml/qqmlecmascript/data/signalAssignment.3.qml b/tests/auto/qml/qqmlecmascript/data/signalAssignment.3.qml new file mode 100644 index 0000000000..690b7cf216 --- /dev/null +++ b/tests/auto/qml/qqmlecmascript/data/signalAssignment.3.qml @@ -0,0 +1,5 @@ +import Qt.test 1.0 + +MyQmlObject { + onUnnamedArgumentSignal: setString('pass ' + a + ' ' + c) +} diff --git a/tests/auto/qml/qqmlecmascript/data/signalAssignment.4.qml b/tests/auto/qml/qqmlecmascript/data/signalAssignment.4.qml new file mode 100644 index 0000000000..0e1e728a86 --- /dev/null +++ b/tests/auto/qml/qqmlecmascript/data/signalAssignment.4.qml @@ -0,0 +1,6 @@ +import Qt.test 1.0 + + +MyQmlObject { + onSignalWithGlobalName: setString('pass ' + parseInt("5")) +} |