Points: add unit tests

This commit is contained in:
wmayer
2023-08-27 17:59:30 +02:00
committed by wwmayer
parent 48202e940e
commit cdd5248721
3 changed files with 32 additions and 0 deletions

View File

@@ -0,0 +1,5 @@
target_sources(
Points_tests_run
PRIVATE
${CMAKE_CURRENT_SOURCE_DIR}/Points.cpp
)

View File

@@ -0,0 +1,12 @@
#include "gtest/gtest.h"
#include <Mod/Points/App/Points.h>
// NOLINTBEGIN(cppcoreguidelines-*,readability-*)
TEST(Points, TestDefault)
{
Points::PointKernel kernel;
std::vector<Points::PointKernel::value_type> points;
kernel.setBasicPoints(points);
EXPECT_EQ(kernel.size(), 0);
}
// NOLINTEND(cppcoreguidelines-*,readability-*)

View File

@@ -0,0 +1,15 @@
target_include_directories(Points_tests_run PUBLIC
${EIGEN3_INCLUDE_DIR}
${OCC_INCLUDE_DIR}
${Python3_INCLUDE_DIRS}
${XercesC_INCLUDE_DIRS}
)
target_link_libraries(Points_tests_run
gtest_main
${Google_Tests_LIBS}
Points
)
add_subdirectory(App)