characteristics_tests.cpp are working

This commit is contained in:
Pcornat 2024-10-30 21:43:09 +01:00
parent 2b59a832a4
commit ca6745d065
Signed by: Pcornat
GPG Key ID: E0326CC678A00BDD
2 changed files with 4 additions and 4 deletions

View File

@ -9,8 +9,8 @@ add_executable(UnitTest adummy.cpp
billy_objects_tests.cpp billy_objects_tests.cpp
) )
set_target_properties(Catch2 UnitTest svector PROPERTIES
CXX_STANDARD 17 CXX_STANDARD 17
set_target_properties(Catch2 UnitTest PROPERTIES
CXX_STANDARD_REQUIRED ON CXX_STANDARD_REQUIRED ON
CXX_EXTENSIONS OFF CXX_EXTENSIONS OFF
INTERPROCEDURAL_OPTIMIZATION_RELEASE ON INTERPROCEDURAL_OPTIMIZATION_RELEASE ON
@ -20,7 +20,7 @@ target_include_directories(UnitTest PRIVATE ${CMAKE_SOURCE_DIR}/include)
target_compile_definitions(UnitTest PRIVATE ${DEF_COMP}) target_compile_definitions(UnitTest PRIVATE ${DEF_COMP})
target_compile_options(UnitTest PRIVATE ${COMPILE_FLAGS} -fdiagnostics-all-candidates) target_compile_options(UnitTest PRIVATE ${COMPILE_FLAGS} -fdiagnostics-all-candidates)
target_link_options(UnitTest PRIVATE ${LINKER_OPTIONS}) target_link_options(UnitTest PRIVATE ${LINKER_OPTIONS})
target_link_libraries(UnitTest ${LINKER_FLAGS} spdlog::spdlog_header_only Catch2::Catch2WithMain nlohmann_json::nlohmann_json svector::svector BillySheet) target_link_libraries(UnitTest ${LINKER_FLAGS} Catch2::Catch2WithMain nlohmann_json::nlohmann_json BillySheet)
enable_testing() enable_testing()
catch_discover_tests(UnitTest WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} REPORTER junit OUTPUT_DIR ${CMAKE_SOURCE_DIR} OUTPUT_PREFIX cppspec- OUTPUT_SUFFIX .xml) catch_discover_tests(UnitTest WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} REPORTER junit OUTPUT_DIR ${CMAKE_SOURCE_DIR} OUTPUT_PREFIX cppspec- OUTPUT_SUFFIX .xml)

View File

@ -1,7 +1,7 @@
#include <catch2/catch_all.hpp> #include <catch2/catch_all.hpp>
#include "characteristic/characteristic.hpp"
#include "character_sheet.hpp"
#include <fstream> #include <fstream>
#include "characteristic.hpp"
#include "character_sheet.hpp"
using namespace character::characteristic; using namespace character::characteristic;