summaryrefslogtreecommitdiffstats
path: root/tests/auto/widgets/widgets/qtextbrowser
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/widgets/widgets/qtextbrowser')
-rw-r--r--tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt6
-rw-r--r--tests/auto/widgets/widgets/qtextbrowser/tst_qtextbrowser.cpp3
2 files changed, 7 insertions, 2 deletions
diff --git a/tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt b/tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt
index b2d6664783..4a80068d75 100644
--- a/tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt
+++ b/tests/auto/widgets/widgets/qtextbrowser/CMakeLists.txt
@@ -5,6 +5,12 @@
## tst_qtextbrowser Test:
#####################################################################
+if(NOT QT_BUILD_STANDALONE_TESTS AND NOT QT_BUILDING_QT)
+ cmake_minimum_required(VERSION 3.16)
+ project(tst_qtextbrowser LANGUAGES CXX)
+ find_package(Qt6BuildInternals REQUIRED COMPONENTS STANDALONE_TEST)
+endif()
+
# Collect test data
file(GLOB_RECURSE test_data_glob
RELATIVE ${CMAKE_CURRENT_SOURCE_DIR}
diff --git a/tests/auto/widgets/widgets/qtextbrowser/tst_qtextbrowser.cpp b/tests/auto/widgets/widgets/qtextbrowser/tst_qtextbrowser.cpp
index 8bc991a962..6dfab07fed 100644
--- a/tests/auto/widgets/widgets/qtextbrowser/tst_qtextbrowser.cpp
+++ b/tests/auto/widgets/widgets/qtextbrowser/tst_qtextbrowser.cpp
@@ -1,5 +1,5 @@
// Copyright (C) 2019 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
#include <QTest>
@@ -19,7 +19,6 @@ class TestBrowser : public QTextBrowser
public:
inline TestBrowser() {
show();
- QApplicationPrivate::setActiveWindow(this);
activateWindow();
setFocus();
QVERIFY(QTest::qWaitForWindowActive(this));