提交 f748f071 编写于 作者: H Hongze Cheng

more

上级 103a6225
...@@ -20,9 +20,13 @@ add_library(api INTERFACE) ...@@ -20,9 +20,13 @@ add_library(api INTERFACE)
target_include_directories(api INTERFACE "include/client") target_include_directories(api INTERFACE "include/client")
# src # src
if(${BUILD_TEST})
include(CTest)
enable_testing()
endif(${BUILD_TEST})
add_subdirectory(source) add_subdirectory(source)
# docs # docs
add_subdirectory(docs) add_subdirectory(docs)
# tests (TODO) # tests (TODO)
\ No newline at end of file
...@@ -4,4 +4,9 @@ target_sources(vnodeApiTests ...@@ -4,4 +4,9 @@ target_sources(vnodeApiTests
PRIVATE PRIVATE
"vnodeApiTests.cpp" "vnodeApiTests.cpp"
) )
target_link_libraries(vnodeApiTests vnode gtest gtest_main) target_link_libraries(vnodeApiTests vnode gtest gtest_main)
\ No newline at end of file
add_test(
NAME vnode_api_tests
COMMAND ${CMAKE_CURRENT_BINARY_DIR}/vnodeApiTests
)
\ No newline at end of file
/**
* @file vnodeApiTests.cpp
* @author hzcheng (hzcheng@taosdata.com)
* @brief VNODE module API tests
* @version 0.1
* @date 2021-12-13
*
* @copyright Copyright (c) 2021
*
*/
#include <gtest/gtest.h> #include <gtest/gtest.h>
#include <iostream> #include <iostream>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册