Warning, /pim/kdepim-addons/plugins/messageviewer/bodypartformatter/autotests/CMakeLists.txt is written in an unsupported language. File is not indexed.
0001 # SPDX-FileCopyrightText: 2015-2024 Laurent Montel <montel@kde.org>
0002 # SPDX-License-Identifier: BSD-3-Clause
0003 set(EXECUTABLE_OUTPUT_PATH ${CMAKE_CURRENT_BINARY_DIR})
0004 add_definitions( -DMAIL_DATA_DIR="${CMAKE_CURRENT_SOURCE_DIR}/data" )
0005 add_definitions( -DDIFF_DATA_DIR="${CMAKE_CURRENT_SOURCE_DIR}/diffdata" )
0006
0007 include(${CMAKE_SOURCE_DIR}/cmake/modules/kdepim_add_gpg_crypto_test.cmake)
0008 add_subdirectory(gnupg_home)
0009
0010 macro(add_kdepimaddons_crypto_unittest _source)
0011 set(_test ${_source})
0012 get_filename_component(_name ${_source} NAME_WE)
0013 add_executable( ${_name} ${_source})
0014 target_link_libraries( ${_name}
0015 KPim6::MessageViewer
0016 Qt::Test
0017
0018 )
0019 add_gpg_crypto_test(${_name} messageviewerplugins-${_name})
0020 ecm_mark_as_test(messageviewerplugins-${_name})
0021 endmacro ()
0022 add_kdepimaddons_crypto_unittest(rendertest.cpp)
0023
0024 if (KDEPIM_RUN_AKONADI_TEST)
0025 add_akonadi_isolated_test(SOURCE rendertest-akonadi.cpp BACKENDS SQLITE LINK_LIBRARIES KPim6::MessageViewer)
0026 target_compile_definitions(rendertest-akonadi PRIVATE -DDATA_DIR="${CMAKE_CURRENT_SOURCE_DIR}/data-akonadi")
0027 endif()
0028
0029 macro(add_messageviewer_bodyformatter_class_unittest _source _additional)
0030 set( _test ${_source} ${common_SRCS} ${_additional})
0031 get_filename_component(_name ${_source} NAME_WE)
0032
0033 ecm_add_test(${_test}
0034 TEST_NAME ${_name}
0035 NAME_PREFIX "messageviewerplugins-"
0036 LINK_LIBRARIES KPim6::MessageViewer Qt::Test KPim6::PimTextEdit KF6::I18n KF6::Completion KPim6::PimCommonAkonadi
0037 )
0038 endmacro ()
0039 add_messageviewer_bodyformatter_class_unittest(reactiontoinvitationdialogtest.cpp "../calendar/reactiontoinvitationdialog.cpp")
0040 add_messageviewer_bodyformatter_class_unittest(delegateselectortest.cpp "../calendar/delegateselector.cpp")
0041
0042 macro(add_diff_bodyformatter_class_unittest _source _additional)
0043 set( _test ${_source} ${common_SRCS} ${_additional})
0044 get_filename_component(_name ${_source} NAME_WE)
0045
0046 ecm_add_test(${_test}
0047 TEST_NAME ${_name}
0048 NAME_PREFIX "messageviewerplugins-"
0049 LINK_LIBRARIES KPim6::MessageViewer Qt::Test KPim6::PimTextEdit KF6::I18n KF6::SyntaxHighlighting
0050 )
0051 endmacro ()
0052
0053 add_diff_bodyformatter_class_unittest(diffhighlightertest.cpp "../highlighter/highlighter.cpp")