aboutsummaryrefslogtreecommitdiff
path: root/lib/webengine/CMakeLists.txt
blob: 3e5fa71b82c76c7502488bf15fc9a54c659db07d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
add_library(webengine STATIC
    webprofile.h webprofile.cpp webprofilemanager.h webprofilemanager.cpp
    webpage.h webpage.cpp
    webview.h webview.cpp webviewcontextmenu.h webviewcontextmenu.cpp
    urlinterceptor.h urlinterceptor.cpp)
target_include_directories(webengine PUBLIC ${CMAKE_SOURCE_DIR}/include ${CMAKE_CURRENT_SOURCE_DIR})
target_link_libraries(webengine PUBLIC Qt5::WebEngineWidgets fmt)

# tests
add_executable(profile_test test/profile.cpp)
target_link_libraries(profile_test PRIVATE webengine Catch2::Catch2)
#target_sanitize(profile_test)

add_executable(profilemanager_test test/profilemanager.cpp)
target_link_libraries(profilemanager_test PRIVATE webengine Catch2::Catch2)
#target_sanitize(profilemanager_test)

add_test(NAME webengine_profile COMMAND profile_test)
add_test(NAME webengine_profilemanager COMMAND profilemanager_test)
set_tests_properties(webengine_profile webengine_profilemanager PROPERTIES
    ENVIRONMENT "PROFILE=${CMAKE_CURRENT_SOURCE_DIR}/test/testing.profile")