Warning, /frameworks/kcodecs/autotests/CMakeLists.txt is written in an unsupported language. File is not indexed.
0001 include(ECMAddTests) 0002 0003 find_package(Qt${QT_MAJOR_VERSION}Test ${REQUIRED_QT_VERSION} CONFIG QUIET) 0004 0005 if(NOT TARGET Qt${QT_MAJOR_VERSION}::Test) 0006 message(STATUS "Qt${QT_MAJOR_VERSION}Test not found, autotests will not be built.") 0007 return() 0008 endif() 0009 0010 ecm_add_tests( 0011 kencodingprobertest.cpp 0012 rfc2047test.cpp 0013 base45test.cpp 0014 codectest.cpp 0015 kemailaddresstest.cpp 0016 LINK_LIBRARIES KF5::Codecs Qt${QT_MAJOR_VERSION}::Test 0017 ) 0018 0019 if (TARGET Qt6::Core5Compat) 0020 set(_qt5_compat_libs Qt6::Core5Compat) # QTextCodec 0021 endif() 0022 0023 ecm_add_test( 0024 kcharsetstest.cpp 0025 LINK_LIBRARIES KF5::Codecs Qt${QT_MAJOR_VERSION}::Test ${_qt5_compat_libs} 0026 ) 0027 0028 ecm_add_test( 0029 ${CMAKE_SOURCE_DIR}/src/kusasciitextcodec.cpp 0030 kusasciitextcodectest.cpp 0031 TEST_NAME kusasciitextcodectest 0032 LINK_LIBRARIES Qt${QT_MAJOR_VERSION}::Test ${_qt5_compat_libs} 0033 ) 0034 target_include_directories(kusasciitextcodectest 0035 PRIVATE "${CMAKE_SOURCE_DIR}/src" 0036 ) 0037 0038 # Benchmark, compiled, but not run automatically with ctest 0039 add_executable(base64benchmark base64benchmark.cpp) 0040 target_link_libraries(base64benchmark KF5::Codecs Qt${QT_MAJOR_VERSION}::Test)