Skip to content

Commit

Permalink
feat: modify section function to print once (#147)
Browse files Browse the repository at this point in the history
  • Loading branch information
threeal authored Jul 4, 2024
1 parent 23ea536 commit 3838638
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions cmake/Assertion.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ function(section NAME)
cmake_parse_arguments(PARSE_ARGV 1 ARG "" "" "")
string(JOIN "" NAME "${NAME}" ${ARG_UNPARSED_ARGUMENTS})

message(CHECK_START "${NAME}")
message(STATUS "${NAME}")
list(APPEND CMAKE_MESSAGE_INDENT " ")
set(CMAKE_MESSAGE_INDENT "${CMAKE_MESSAGE_INDENT}" PARENT_SCOPE)
endfunction()
Expand All @@ -312,11 +312,10 @@ endfunction()
#
# endsection()
#
# This function ends the current test section and marks it as passed.
# This function ends the current test section.
function(endsection)
list(POP_BACK CMAKE_MESSAGE_INDENT)
set(CMAKE_MESSAGE_INDENT "${CMAKE_MESSAGE_INDENT}" PARENT_SCOPE)
message(CHECK_PASS passed)
endfunction()

# These lines allow this module to include other modules when run in script mode
Expand Down

0 comments on commit 3838638

Please sign in to comment.