mirror of
https://github.com/falcosecurity/falco.git
synced 2025-06-26 06:42:08 +00:00
new: attach tests to main cmake and base test
Signed-off-by: Lorenzo Fontana <lo@linux.com> Co-authored-by: Leonardo Di Donato <leodidonato@gmail.com>
This commit is contained in:
parent
18b66330ec
commit
026f6866e3
@ -610,6 +610,10 @@ add_subdirectory(docker)
|
||||
list(APPEND CMAKE_MODULE_PATH
|
||||
"${SYSDIG_DIR}/cmake/modules")
|
||||
|
||||
# Add path for custom CMake modules
|
||||
list(APPEND CMAKE_MODULE_PATH
|
||||
"${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules")
|
||||
|
||||
if(CMAKE_SYSTEM_NAME MATCHES "Linux")
|
||||
add_subdirectory("${SYSDIG_DIR}/driver" "${PROJECT_BINARY_DIR}/driver")
|
||||
include(FindMakedev)
|
||||
@ -624,6 +628,7 @@ set(FALCO_BIN_DIR bin)
|
||||
add_subdirectory(scripts)
|
||||
add_subdirectory(userspace/engine)
|
||||
add_subdirectory(userspace/falco)
|
||||
add_subdirectory(tests)
|
||||
|
||||
|
||||
set(CPACK_PACKAGE_NAME "${PACKAGE_NAME}")
|
||||
|
5
tests/TestBase.cpp
Normal file
5
tests/TestBase.cpp
Normal file
@ -0,0 +1,5 @@
|
||||
#define CATCH_CONFIG_MAIN
|
||||
#include <catch.hpp>
|
||||
|
||||
TEST_CASE( "1: All test cases reside in other .cpp files (empty)", "[multi-file:1]" ) {
|
||||
}
|
@ -24,7 +24,7 @@ include_directories("${NJSON_INCLUDE}")
|
||||
include_directories("${CURL_INCLUDE_DIR}")
|
||||
include_directories("${TBB_INCLUDE_DIR}")
|
||||
|
||||
add_library(falco_engine STATIC
|
||||
set(FALCO_ENGINE_SOURCE_FILES
|
||||
rules.cpp
|
||||
falco_common.cpp
|
||||
falco_engine.cpp
|
||||
@ -33,6 +33,8 @@ add_library(falco_engine STATIC
|
||||
token_bucket.cpp
|
||||
formats.cpp)
|
||||
|
||||
add_library(falco_engine STATIC ${FALCO_ENGINE_SOURCE_FILES})
|
||||
|
||||
target_include_directories(falco_engine PUBLIC
|
||||
"${LUAJIT_INCLUDE}"
|
||||
"${NJSON_INCLUDE}"
|
||||
@ -43,6 +45,7 @@ target_link_libraries(falco_engine
|
||||
"${LPEG_LIB}"
|
||||
"${LYAML_LIB}"
|
||||
"${LIBYAML_LIB}")
|
||||
# --coverage) # todo: enable only if coverage enabled
|
||||
|
||||
configure_file(config_falco_engine.h.in config_falco_engine.h)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user