Skip to content

Commit

Permalink
ServiceComponent build tests cmake configuration (#949) (#953)
Browse files Browse the repository at this point in the history
* use cmake build type

* set to debug by default

Co-authored-by: tcormackMW <113473781+tcormackMW@users.noreply.github.com>
  • Loading branch information
insi-eb and tcormackMW committed Oct 27, 2023
1 parent c176b85 commit 8e211a8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ endforeach()
# Set a default build type if none was specified
#-----------------------------------------------------------------------------

if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
if(NOT CMAKE_BUILD_TYPE)
message(STATUS "Setting build type to 'Debug' as none was specified.")
set(CMAKE_BUILD_TYPE Debug CACHE STRING "Choose the type of build." FORCE)

Expand Down
2 changes: 1 addition & 1 deletion compendium/ServiceComponent/test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ foreach(exe_name ${compile_only_exe_names})

#For compile-only tests we add a test with Cmake command to build the target only as we expect a build failure
add_test(NAME ${exe_name}
COMMAND ${CMAKE_COMMAND} --build . --target ${exe_name}
COMMAND ${CMAKE_COMMAND} --build . --config ${CMAKE_BUILD_TYPE} --target ${exe_name}
WORKING_DIRECTORY ${CppMicroServices_BINARY_DIR}
)

Expand Down

0 comments on commit 8e211a8

Please sign in to comment.