]> git.stg.codes - stg.git/blob - tests/CMakeLists.txt
Disable cppcheck for foreign libs by default.
[stg.git] / tests / CMakeLists.txt
1 set ( THREADS_PREFER_PTHREAD_FLAG ON )
2 find_package ( Threads REQUIRED )
3 find_package ( Boost REQUIRED unit_test_framework )
4
5 add_definitions ( -DBOOST_TEST_DYN_LINK )
6 add_definitions ( -DUSE_ABSTRACT_SETTINGS )
7
8 add_executable ( test_admin_conf test_admin_conf.cpp )
9 target_link_libraries ( test_admin_conf Boost::unit_test_framework )
10 add_test ( admin_conf test_admin_conf )
11
12 add_executable ( test_raw_ip test_raw_ip.cpp )
13 target_link_libraries ( test_raw_ip Boost::unit_test_framework )
14 add_test ( raw_ip test_raw_ip )
15
16 add_executable ( test_bfstream test_bfstream.cpp )
17 target_link_libraries ( test_bfstream crypto Boost::unit_test_framework )
18 add_test ( bfstream test_bfstream )
19
20 add_executable ( test_crypto test_crypto.cpp )
21 target_link_libraries ( test_crypto crypto Boost::unit_test_framework )
22 add_test ( stgcrypto test_crypto )
23
24 add_executable ( test_tariff test_tariff.cpp ../projects/stargazer/tariff_impl.cpp )
25 target_link_libraries ( test_tariff crypto common Boost::unit_test_framework )
26 target_include_directories ( test_tariff PRIVATE ${CMAKE_CURRENT_SOURCE_DIR} ../projects/stargazer )
27 add_test ( tariff test_tariff )
28
29 add_executable ( test_conffiles test_conffiles.cpp )
30 target_link_libraries ( test_conffiles conffiles Boost::unit_test_framework )
31 add_test ( stgconffiles test_conffiles )
32
33 add_executable ( test_fee_charge_rules test_fee_charge_rules.cpp ../projects/stargazer/user_impl.cpp ../projects/stargazer/tariff_impl.cpp ../projects/stargazer/user_property.cpp )
34 target_link_libraries ( test_fee_charge_rules logger scriptexecuter common Boost::unit_test_framework Threads::Threads )
35 target_include_directories ( test_fee_charge_rules PRIVATE ${CMAKE_CURRENT_SOURCE_DIR} ../projects/stargazer )
36 add_test ( fee_charge_rules test_fee_charge_rules )
37
38 add_executable ( test_reconnect_on_tariff_change test_reconnect_on_tariff_change.cpp ../projects/stargazer/user_impl.cpp ../projects/stargazer/tariff_impl.cpp ../projects/stargazer/user_property.cpp )
39 target_link_libraries ( test_reconnect_on_tariff_change logger scriptexecuter common Boost::unit_test_framework Threads::Threads )
40 target_include_directories ( test_reconnect_on_tariff_change PRIVATE ${CMAKE_CURRENT_SOURCE_DIR} ../projects/stargazer )
41 add_test ( reconnect_on_tariff_change test_reconnect_on_tariff_change )
42
43 add_executable ( test_disable_session_log test_disable_session_log.cpp ../projects/stargazer/user_impl.cpp ../projects/stargazer/tariff_impl.cpp ../projects/stargazer/user_property.cpp )
44 target_link_libraries ( test_disable_session_log logger scriptexecuter common Boost::unit_test_framework Threads::Threads )
45 target_include_directories ( test_disable_session_log PRIVATE ${CMAKE_CURRENT_SOURCE_DIR} ../projects/stargazer )
46 add_test ( disable_session_log test_disable_session_log )
47
48 add_executable ( test_filter_params_log test_filter_params_log.cpp ../projects/stargazer/user_impl.cpp ../projects/stargazer/tariff_impl.cpp ../projects/stargazer/user_property.cpp )
49 target_link_libraries ( test_filter_params_log logger scriptexecuter common Boost::unit_test_framework Threads::Threads )
50 target_include_directories ( test_filter_params_log PRIVATE ${CMAKE_CURRENT_SOURCE_DIR} ../projects/stargazer )
51 add_test ( filter_params_log test_filter_params_log )
52
53 add_executable ( test_subscriptions test_subscriptions.cpp )
54 target_link_libraries ( test_subscriptions Boost::unit_test_framework )
55 add_test ( subscriptions test_subscriptions )
56
57 add_executable ( test_async_pool test_async_pool.cpp ../projects/stargazer/async_pool.cpp )
58 target_include_directories ( test_async_pool PRIVATE ${CMAKE_CURRENT_SOURCE_DIR} ../projects/stargazer )
59 target_link_libraries ( test_async_pool Boost::unit_test_framework Threads::Threads )
60 add_test ( async_pool test_async_pool )