summaryrefslogtreecommitdiffstats
path: root/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt')
-rw-r--r--tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt81
1 files changed, 32 insertions, 49 deletions
diff --git a/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt
index ddc5b99baa..729ac3933a 100644
--- a/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt
+++ b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt
@@ -1,4 +1,11 @@
-# Generated from qmimedatabase-xml.pro.
+# Copyright (C) 2022 The Qt Company Ltd.
+# SPDX-License-Identifier: BSD-3-Clause
+
+if(NOT QT_BUILD_STANDALONE_TESTS AND NOT QT_BUILDING_QT)
+ cmake_minimum_required(VERSION 3.16)
+ project(tst_qmimedatabase LANGUAGES CXX)
+ find_package(Qt6BuildInternals REQUIRED COMPONENTS STANDALONE_TEST)
+endif()
if(NOT QT_FEATURE_private_tests)
return()
@@ -12,58 +19,31 @@ qt_internal_add_test(tst_qmimedatabase-xml
SOURCES
../tst_qmimedatabase.h
tst_qmimedatabase-xml.cpp
- PUBLIC_LIBRARIES
+ LIBRARIES
Qt::Concurrent
+ Qt::CorePrivate
)
# Resources:
-# special case begin
# the freedesktop resources are handled manually below via mimetypes_resources.cmake
#set(mimetypes_resource_files
#"mime/packages/freedesktop.org.xml"
#)
-# special case end
-set_source_files_properties("../invalid-magic1.xml"
- PROPERTIES QT_RESOURCE_ALIAS "invalid-magic1.xml"
-)
-set_source_files_properties("../invalid-magic2.xml"
- PROPERTIES QT_RESOURCE_ALIAS "invalid-magic2.xml"
-)
-set_source_files_properties("../invalid-magic3.xml"
- PROPERTIES QT_RESOURCE_ALIAS "invalid-magic3.xml"
-)
-set_source_files_properties("../magic-and-hierarchy.foo"
- PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy.foo"
-)
-set_source_files_properties("../magic-and-hierarchy.xml"
- PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy.xml"
-)
-set_source_files_properties("../magic-and-hierarchy2.foo"
- PROPERTIES QT_RESOURCE_ALIAS "magic-and-hierarchy2.foo"
-)
-set_source_files_properties("../qml-again.xml"
- PROPERTIES QT_RESOURCE_ALIAS "qml-again.xml"
-)
-set_source_files_properties("../test.qml"
- PROPERTIES QT_RESOURCE_ALIAS "test.qml"
-)
-set_source_files_properties("../text-x-objcsrc.xml"
- PROPERTIES QT_RESOURCE_ALIAS "text-x-objcsrc.xml"
-)
-set_source_files_properties("../yast2-metapackage-handler-mimetypes.xml"
- PROPERTIES QT_RESOURCE_ALIAS "yast2-metapackage-handler-mimetypes.xml"
-)
set(testdata_resource_files
- "invalid-magic1.xml"
- "invalid-magic2.xml"
- "invalid-magic3.xml"
- "magic-and-hierarchy.foo"
- "magic-and-hierarchy.xml"
- "magic-and-hierarchy2.foo"
- "qml-again.xml"
- "test.qml"
- "text-x-objcsrc.xml"
- "yast2-metapackage-handler-mimetypes.xml"
+ "../add-extension.xml"
+ "../circular-inheritance.xml"
+ "../invalid-magic1.xml"
+ "../invalid-magic2.xml"
+ "../invalid-magic3.xml"
+ "../magic-and-hierarchy.foo"
+ "../magic-and-hierarchy.xml"
+ "../magic-and-hierarchy2.foo"
+ "../qml-again.xml"
+ "../test.qml"
+ "../text-x-objcsrc.xml"
+ "../text-plain-subclass.xml"
+ "../webm-glob-deleteall.xml"
+ "../yast2-metapackage-handler-mimetypes.xml"
)
qt_internal_add_resource(tst_qmimedatabase-xml "testdata"
@@ -75,14 +55,17 @@ qt_internal_add_resource(tst_qmimedatabase-xml "testdata"
${testdata_resource_files}
)
-# special case begin
+qt_internal_add_resource(tst_qmimedatabase-xml "testfiles"
+ PREFIX
+ "/files"
+ FILES
+ "../test.txt"
+ "../test.qml"
+)
+
set(corelib_source_dir ../../../../../../src/corelib)
include(${corelib_source_dir}/mimetypes/mimetypes_resources.cmake)
corelib_add_mimetypes_resources(tst_qmimedatabase-xml)
-# special case end
-
-#### Keys ignored in scope 1:.:.:qmimedatabase-xml.pro:<TRUE>:
-# _REQUIREMENTS = "qtConfig(private_tests)"
## Scopes:
#####################################################################