diff --git a/Tests/QtAutogen/CMakeLists.txt b/Tests/QtAutogen/CMakeLists.txt index 85029d1422..9125bd7800 100644 --- a/Tests/QtAutogen/CMakeLists.txt +++ b/Tests/QtAutogen/CMakeLists.txt @@ -59,18 +59,6 @@ if(NON_ASCII_BDIR AND WIN32) set(ALLOW_WRAP_CPP FALSE) endif() -# -- Test -# RCC only -add_executable(rccOnly rccOnly.cpp rccOnlyRes.qrc) -set_property(TARGET rccOnly PROPERTY AUTORCC ON) -target_link_libraries(rccOnly ${QT_QTCORE_TARGET}) - -# -- Test -# RCC empty -add_executable(rccEmpty rccEmpty.cpp rccEmptyRes.qrc) -set_property(TARGET rccEmpty PROPERTY AUTORCC ON) -target_link_libraries(rccEmpty ${QT_QTCORE_TARGET}) - # -- Test # Add not_generated_file.qrc to the source list to get the file-level # dependency, but don't generate a c++ file from it. Disable the AUTORCC diff --git a/Tests/QtAutogen/CommonTests.cmake b/Tests/QtAutogen/CommonTests.cmake index 9121f41e9c..0950062c2b 100644 --- a/Tests/QtAutogen/CommonTests.cmake +++ b/Tests/QtAutogen/CommonTests.cmake @@ -4,3 +4,5 @@ ADD_AUTOGEN_TEST(MocOptions mocOptions) if(QT_TEST_ALLOW_QT_MACROS) ADD_AUTOGEN_TEST(UicOnly uicOnly) endif() +ADD_AUTOGEN_TEST(RccOnly rccOnly) +ADD_AUTOGEN_TEST(RccEmpty rccEmpty) diff --git a/Tests/QtAutogen/RccEmpty/CMakeLists.txt b/Tests/QtAutogen/RccEmpty/CMakeLists.txt new file mode 100644 index 0000000000..3b16edc430 --- /dev/null +++ b/Tests/QtAutogen/RccEmpty/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.10) +project(RccEmpty) +include("../AutogenTest.cmake") + +# Test AUTORCC on a .qrc file with no resource files +add_executable(rccEmpty rccEmpty.cpp rccEmptyRes.qrc) +set_property(TARGET rccEmpty PROPERTY AUTORCC ON) +target_link_libraries(rccEmpty ${QT_QTCORE_TARGET}) diff --git a/Tests/QtAutogen/rccEmpty.cpp b/Tests/QtAutogen/RccEmpty/rccEmpty.cpp similarity index 100% rename from Tests/QtAutogen/rccEmpty.cpp rename to Tests/QtAutogen/RccEmpty/rccEmpty.cpp diff --git a/Tests/QtAutogen/rccEmptyRes.qrc b/Tests/QtAutogen/RccEmpty/rccEmptyRes.qrc similarity index 100% rename from Tests/QtAutogen/rccEmptyRes.qrc rename to Tests/QtAutogen/RccEmpty/rccEmptyRes.qrc diff --git a/Tests/QtAutogen/RccOnly/CMakeLists.txt b/Tests/QtAutogen/RccOnly/CMakeLists.txt new file mode 100644 index 0000000000..a65dee4d87 --- /dev/null +++ b/Tests/QtAutogen/RccOnly/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.10) +project(RccOnly) +include("../AutogenTest.cmake") + +# Test AUTORCC being enabled only +add_executable(rccOnly rccOnly.cpp rccOnlyRes.qrc) +set_property(TARGET rccOnly PROPERTY AUTORCC ON) +target_link_libraries(rccOnly ${QT_QTCORE_TARGET}) diff --git a/Tests/QtAutogen/rccOnly.cpp b/Tests/QtAutogen/RccOnly/rccOnly.cpp similarity index 100% rename from Tests/QtAutogen/rccOnly.cpp rename to Tests/QtAutogen/RccOnly/rccOnly.cpp diff --git a/Tests/QtAutogen/rccOnlyRes.qrc b/Tests/QtAutogen/RccOnly/rccOnlyRes.qrc similarity index 100% rename from Tests/QtAutogen/rccOnlyRes.qrc rename to Tests/QtAutogen/RccOnly/rccOnlyRes.qrc