diff options
Diffstat (limited to 'tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml')
-rw-r--r-- | tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt | 31 | ||||
-rw-r--r-- | tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/tst_qmimedatabase-xml.cpp | 32 |
2 files changed, 25 insertions, 38 deletions
diff --git a/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/CMakeLists.txt index 47e9a2f1d7..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,18 +19,19 @@ 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(testdata_resource_files + "../add-extension.xml" + "../circular-inheritance.xml" "../invalid-magic1.xml" "../invalid-magic2.xml" "../invalid-magic3.xml" @@ -33,6 +41,8 @@ set(testdata_resource_files "../qml-again.xml" "../test.qml" "../text-x-objcsrc.xml" + "../text-plain-subclass.xml" + "../webm-glob-deleteall.xml" "../yast2-metapackage-handler-mimetypes.xml" ) @@ -45,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: ##################################################################### diff --git a/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/tst_qmimedatabase-xml.cpp b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/tst_qmimedatabase-xml.cpp index e403baf714..f86c8b8839 100644 --- a/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/tst_qmimedatabase-xml.cpp +++ b/tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/tst_qmimedatabase-xml.cpp @@ -1,36 +1,10 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only -#include "../tst_qmimedatabase.h" +#include "../tst_qmimedatabase.cpp" void tst_QMimeDatabase::initTestCaseInternal() { qputenv("QT_NO_MIME_CACHE", "1"); } -#include "../tst_qmimedatabase.cpp" |