From dae9249098c24b2771bc28258d10c968e702cd4b Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@savoirfairelinux.com>
Date: Sun, 6 Nov 2022 00:16:34 -0400
Subject: [PATCH] tests: Add missing QtWidgets dependency.

Fixes <https://git.jami.net/savoirfairelinux/jami-client-qt/-/issues/882>.

* tests/CMakeLists.txt: Add "Widgets" Qt module to find_package call.
(QML_TEST_LIBS): Add Qt::Widgets.

Change-Id: I695010776e6d2638fb65009c79f3263269e1020e
---
 tests/CMakeLists.txt | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 8904d5ec9..b30425b7e 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -1,4 +1,4 @@
-find_package(Qt${QT_VERSION_MAJOR} CONFIG REQUIRED QuickTest Test)
+find_package(Qt${QT_VERSION_MAJOR} CONFIG REQUIRED QuickTest Widgets Test)
 
 if(MSVC)
     # Download and unpack googletest for windows
@@ -15,7 +15,7 @@ else()
 endif()
 
 enable_testing(true)
-set(QML_TEST_LIBS ${QML_LIBS} Qt::QuickTest Qt::Test)
+set(QML_TEST_LIBS ${QML_LIBS} Qt::QuickTest Qt::Widgets Qt::Test)
 set(TESTS_INCLUDES
     ${CMAKE_SOURCE_DIR}/src
     ${CMAKE_SOURCE_DIR}/tests/qml
@@ -192,4 +192,4 @@ else()
                                ${LRC}/include)
 
     add_test(NAME UnitTests COMMAND unittests)
-endif()
\ No newline at end of file
+endif()
-- 
GitLab