Skip to content

Commit

Permalink
Add messaging and comment to test script
Browse files Browse the repository at this point in the history
  • Loading branch information
Blake-Madden committed May 28, 2024
1 parent 2fb0034 commit 8820c20
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,14 @@ if(CLANG_TIDY_COMMAND AND USE_CLANG_TIDY)
endif()
endif()

if(USE_ADDRESS_SANITIZE)
message(STATUS "Address Sanitizer enabled")
endif()

if(USE_CLANG_TIDY)
message(STATUS "clang-tidy enabled")
endif()

if(TE_FLOAT)
message(STATUS "Datatype: float")
add_definitions(-DTE_FLOAT)
Expand Down Expand Up @@ -89,6 +97,9 @@ add_executable(${CMAKE_PROJECT_NAME} ../tinyexpr.cpp tetests.cpp testingmain.cpp
if(MSVC)
target_compile_definitions(${CMAKE_PROJECT_NAME} PUBLIC _DISABLE_VECTOR_ANNOTATION _DISABLE_STRING_ANNOTATION
$<$<CONFIG:Release>:NDEBUG>)
# This warning:
# C4554: check operator precedence for possible error; use parentheses to clarify precedence
# is suppressed because of unit test, not the code itself.
if(USE_ADDRESS_SANITIZE)
target_compile_options(${CMAKE_PROJECT_NAME} PUBLIC /Zc:__cplusplus /MP /W3 /WX /wd4554
$<$<CONFIG:Debug>:/Od /fsanitize=address> $<$<CONFIG:Release>:/O2>)
Expand Down

0 comments on commit 8820c20

Please sign in to comment.