aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/qmlcachegen/tst_qmlcachegen.cpp
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2019-08-28 07:34:06 +0200
committerQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2019-08-28 07:34:06 +0200
commitf6ab93a9f96b163cb82f4a2c0971d4fd5cc81fb4 (patch)
treea4f77a581a2ac38ff1617d046c8c37abc741a117 /tests/auto/qml/qmlcachegen/tst_qmlcachegen.cpp
parent0ae01dec7aa0ffbb59e6e947bfa2e73ae030346a (diff)
parent8577f12bf4dfd9adfe8c5b85a3712bf1cc5ba0c3 (diff)
Merge remote-tracking branch 'origin/5.12' into 5.13
Diffstat (limited to 'tests/auto/qml/qmlcachegen/tst_qmlcachegen.cpp')
-rw-r--r--tests/auto/qml/qmlcachegen/tst_qmlcachegen.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/auto/qml/qmlcachegen/tst_qmlcachegen.cpp b/tests/auto/qml/qmlcachegen/tst_qmlcachegen.cpp
index 5462e6c8ae..741989e732 100644
--- a/tests/auto/qml/qmlcachegen/tst_qmlcachegen.cpp
+++ b/tests/auto/qml/qmlcachegen/tst_qmlcachegen.cpp
@@ -64,6 +64,7 @@ private slots:
void qrcScriptImport();
void fsScriptImport();
void moduleScriptImport();
+ void esModulesViaQJSEngine();
void enums();
@@ -604,6 +605,15 @@ void tst_qmlcachegen::moduleScriptImport()
}
}
+void tst_qmlcachegen::esModulesViaQJSEngine()
+{
+ QCOMPARE(QFileInfo(":/data/module.mjs").size(), 0);
+ QJSEngine engine;
+ QJSValue module = engine.importModule(":/data/module.mjs");
+ QJSValue result = module.property("entry").call();
+ QCOMPARE(result.toString(), "ok");
+}
+
void tst_qmlcachegen::enums()
{
QQmlEngine engine;