diff --git a/tests/auto/qml/CMakeLists.txt b/tests/auto/qml/CMakeLists.txt index 0044a5d817..b1ecfb8849 100644 --- a/tests/auto/qml/CMakeLists.txt +++ b/tests/auto/qml/CMakeLists.txt @@ -33,7 +33,7 @@ add_subdirectory(qqmlsettings) add_subdirectory(qmldiskcache) add_subdirectory(qqmlmetatype) if(TARGET Qt::Quick) - add_subdirectory(qmlcompiler_manual) + add_subdirectory(qmltc_manual) endif() add_subdirectory(qmlbasicapp) if(TARGET Qt::Widgets) diff --git a/tests/auto/qml/qmlcompiler_manual/CMakeLists.txt b/tests/auto/qml/qmltc_manual/CMakeLists.txt similarity index 68% rename from tests/auto/qml/qmlcompiler_manual/CMakeLists.txt rename to tests/auto/qml/qmltc_manual/CMakeLists.txt index ec9bb2a76f..a4aa336ea8 100644 --- a/tests/auto/qml/qmlcompiler_manual/CMakeLists.txt +++ b/tests/auto/qml/qmltc_manual/CMakeLists.txt @@ -4,11 +4,11 @@ file(GLOB_RECURSE test_data_glob data/*) list(APPEND test_data ${test_data_glob}) -qt_internal_add_test(tst_qmlcompiler_manual +qt_internal_add_test(tst_qmltc_manual SOURCES ../../shared/util.cpp ../../shared/util.h testclasses.h - tst_qmlcompiler_manual.cpp + tst_qmltc_manual.cpp INCLUDE_DIRECTORIES ../../shared LIBRARIES @@ -17,7 +17,7 @@ qt_internal_add_test(tst_qmlcompiler_manual Qt::Quick ) -qt6_add_qml_module(tst_qmlcompiler_manual +qt6_add_qml_module(tst_qmltc_manual VERSION 1.0 URI "QmltcManualTests" NO_CREATE_PLUGIN_TARGET @@ -25,12 +25,12 @@ qt6_add_qml_module(tst_qmlcompiler_manual ${test_data} ) -qt_internal_extend_target(tst_qmlcompiler_manual CONDITION ANDROID OR IOS +qt_internal_extend_target(tst_qmltc_manual CONDITION ANDROID OR IOS DEFINES QT_QMLTEST_DATADIR=\\\":/data\\\" ) -qt_internal_extend_target(tst_qmlcompiler_manual CONDITION NOT ANDROID AND NOT IOS +qt_internal_extend_target(tst_qmltc_manual CONDITION NOT ANDROID AND NOT IOS DEFINES QT_QMLTEST_DATADIR=\\\"${CMAKE_CURRENT_SOURCE_DIR}/data\\\" ) diff --git a/tests/auto/qml/qmlcompiler_manual/data/HelloWorld.qml b/tests/auto/qml/qmltc_manual/data/HelloWorld.qml similarity index 100% rename from tests/auto/qml/qmlcompiler_manual/data/HelloWorld.qml rename to tests/auto/qml/qmltc_manual/data/HelloWorld.qml diff --git a/tests/auto/qml/qmlcompiler_manual/data/LocallyImported.qml b/tests/auto/qml/qmltc_manual/data/LocallyImported.qml similarity index 100% rename from tests/auto/qml/qmlcompiler_manual/data/LocallyImported.qml rename to tests/auto/qml/qmltc_manual/data/LocallyImported.qml diff --git a/tests/auto/qml/qmlcompiler_manual/data/changingBindings.qml b/tests/auto/qml/qmltc_manual/data/changingBindings.qml similarity index 100% rename from tests/auto/qml/qmlcompiler_manual/data/changingBindings.qml rename to tests/auto/qml/qmltc_manual/data/changingBindings.qml diff --git a/tests/auto/qml/qmlcompiler_manual/data/javaScriptFunctions.qml b/tests/auto/qml/qmltc_manual/data/javaScriptFunctions.qml similarity index 100% rename from tests/auto/qml/qmlcompiler_manual/data/javaScriptFunctions.qml rename to tests/auto/qml/qmltc_manual/data/javaScriptFunctions.qml diff --git a/tests/auto/qml/qmlcompiler_manual/data/localImport.qml b/tests/auto/qml/qmltc_manual/data/localImport.qml similarity index 100% rename from tests/auto/qml/qmlcompiler_manual/data/localImport.qml rename to tests/auto/qml/qmltc_manual/data/localImport.qml diff --git a/tests/auto/qml/qmlcompiler_manual/data/neighbors.qml b/tests/auto/qml/qmltc_manual/data/neighbors.qml similarity index 100% rename from tests/auto/qml/qmlcompiler_manual/data/neighbors.qml rename to tests/auto/qml/qmltc_manual/data/neighbors.qml diff --git a/tests/auto/qml/qmlcompiler_manual/data/propertyAlias.qml b/tests/auto/qml/qmltc_manual/data/propertyAlias.qml similarity index 100% rename from tests/auto/qml/qmlcompiler_manual/data/propertyAlias.qml rename to tests/auto/qml/qmltc_manual/data/propertyAlias.qml diff --git a/tests/auto/qml/qmlcompiler_manual/data/propertyChangeHandler.qml b/tests/auto/qml/qmltc_manual/data/propertyChangeHandler.qml similarity index 100% rename from tests/auto/qml/qmlcompiler_manual/data/propertyChangeHandler.qml rename to tests/auto/qml/qmltc_manual/data/propertyChangeHandler.qml diff --git a/tests/auto/qml/qmlcompiler_manual/data/propertyReturningFunction.qml b/tests/auto/qml/qmltc_manual/data/propertyReturningFunction.qml similarity index 100% rename from tests/auto/qml/qmlcompiler_manual/data/propertyReturningFunction.qml rename to tests/auto/qml/qmltc_manual/data/propertyReturningFunction.qml diff --git a/tests/auto/qml/qmlcompiler_manual/data/signalHandlers.qml b/tests/auto/qml/qmltc_manual/data/signalHandlers.qml similarity index 100% rename from tests/auto/qml/qmlcompiler_manual/data/signalHandlers.qml rename to tests/auto/qml/qmltc_manual/data/signalHandlers.qml diff --git a/tests/auto/qml/qmlcompiler_manual/testclasses.h b/tests/auto/qml/qmltc_manual/testclasses.h similarity index 100% rename from tests/auto/qml/qmlcompiler_manual/testclasses.h rename to tests/auto/qml/qmltc_manual/testclasses.h diff --git a/tests/auto/qml/qmlcompiler_manual/tst_qmlcompiler_manual.cpp b/tests/auto/qml/qmltc_manual/tst_qmltc_manual.cpp similarity index 98% rename from tests/auto/qml/qmlcompiler_manual/tst_qmlcompiler_manual.cpp rename to tests/auto/qml/qmltc_manual/tst_qmltc_manual.cpp index a12afdd848..b36db62b8e 100644 --- a/tests/auto/qml/qmlcompiler_manual/tst_qmlcompiler_manual.cpp +++ b/tests/auto/qml/qmltc_manual/tst_qmltc_manual.cpp @@ -47,7 +47,7 @@ #include #include -class tst_qmlcompiler_manual : public QQmlDataTest +class tst_qmltc_manual : public QQmlDataTest { Q_OBJECT @@ -68,7 +68,7 @@ private: void signalHandlers_impl(const QUrl &url); }; -void tst_qmlcompiler_manual::cppBinding() +void tst_qmltc_manual::cppBinding() { QQmlEngine e; HelloWorld::url = testFileUrl("HelloWorld.qml"); @@ -85,7 +85,7 @@ void tst_qmlcompiler_manual::cppBinding() QCOMPARE(created.getGreeting(), QStringLiteral("Hello, Qml!")); } -void tst_qmlcompiler_manual::signalHandlers_impl(const QUrl &url) +void tst_qmltc_manual::signalHandlers_impl(const QUrl &url) { QQmlEngine e; ANON_signalHandlers::url = url; @@ -125,19 +125,19 @@ void tst_qmlcompiler_manual::signalHandlers_impl(const QUrl &url) QCOMPARE(created.property("signal2P3").toString(), QStringLiteral("abc0")); } -void tst_qmlcompiler_manual::signalHandlers() +void tst_qmltc_manual::signalHandlers() { // use QQmlTypeCompiler's compilation unit signalHandlers_impl(testFileUrl("signalHandlers.qml")); } -void tst_qmlcompiler_manual::signalHandlers_qmlcachegen() +void tst_qmltc_manual::signalHandlers_qmlcachegen() { // use qmlcachegen's compilation unit signalHandlers_impl(QUrl("qrc:/QmltcManualTests/data/signalHandlers.qml")); } -void tst_qmlcompiler_manual::jsFunctions() +void tst_qmltc_manual::jsFunctions() { QQmlEngine e; ANON_javaScriptFunctions::url = testFileUrl("javaScriptFunctions.qml"); @@ -154,7 +154,7 @@ void tst_qmlcompiler_manual::jsFunctions() QCOMPARE(created.func3(), true); } -void tst_qmlcompiler_manual::changingBindings() +void tst_qmltc_manual::changingBindings() { QQmlEngine e; ANON_changingBindings::url = testFileUrl("changingBindings.qml"); @@ -200,7 +200,7 @@ void tst_qmlcompiler_manual::changingBindings() QCOMPARE(created.initialBindingCallCount, 2); } -void tst_qmlcompiler_manual::propertyAlias() +void tst_qmltc_manual::propertyAlias() { QQmlEngine e; ANON_propertyAlias::url = testFileUrl("propertyAlias.qml"); @@ -261,7 +261,7 @@ void tst_qmlcompiler_manual::propertyAlias() QCOMPARE(created.getAliasToOrigin(), -24); } -void tst_qmlcompiler_manual::propertyChangeHandler() +void tst_qmltc_manual::propertyChangeHandler() { QQmlEngine e; ANON_propertyChangeHandler::url = testFileUrl("propertyChangeHandler.qml"); @@ -290,7 +290,7 @@ void tst_qmlcompiler_manual::propertyChangeHandler() QCOMPARE(created.property("watcher").toInt(), 96); } -void tst_qmlcompiler_manual::propertyReturningFunction() +void tst_qmltc_manual::propertyReturningFunction() { QQmlEngine e; ANON_propertyReturningFunction::url = testFileUrl("propertyReturningFunction.qml"); @@ -305,7 +305,7 @@ void tst_qmlcompiler_manual::propertyReturningFunction() QCOMPARE(created.getCounter(), 0); } -void tst_qmlcompiler_manual::locallyImported() +void tst_qmltc_manual::locallyImported() { QQmlEngine e; LocallyImported::url = testFileUrl("LocallyImported.qml"); @@ -318,7 +318,7 @@ void tst_qmlcompiler_manual::locallyImported() QCOMPARE(qvariant_cast(ctx->contextProperty("foo")), &created); } -void tst_qmlcompiler_manual::localImport() +void tst_qmltc_manual::localImport() { // NB: compare object creation compiler against QQmlComponent { @@ -395,7 +395,7 @@ void tst_qmlcompiler_manual::localImport() } } -void tst_qmlcompiler_manual::neighbors() +void tst_qmltc_manual::neighbors() { { QQmlEngine e; @@ -421,7 +421,7 @@ void tst_qmlcompiler_manual::neighbors() QCOMPARE(rootQmlCtx->objectForName("child2"), children.at(1)); } - // this case is different from tst_qmlcompiler_manual::localImport() as + // this case is different from tst_qmltc_manual::localImport() as // LocallyImported is not a parent of a document root. Thus, the context // hierarchy: // * ANON_neighbors: rootContext -> neighborsContext @@ -1204,6 +1204,6 @@ void ANON_neighbors::finalize(QQmlEngine *e) QUrl ANON_neighbors::url = QUrl(); // workaround -QTEST_MAIN(tst_qmlcompiler_manual) +QTEST_MAIN(tst_qmltc_manual) -#include "tst_qmlcompiler_manual.moc" +#include "tst_qmltc_manual.moc"