Skip to content

Commit

Permalink
Just print status on CMake below 3.14
Browse files Browse the repository at this point in the history
  • Loading branch information
byrnHDF committed Sep 25, 2023
1 parent d47f41e commit f9eedd1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions config/cmake/fileCompareTest.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,11 @@ if (TEST_STRINGS STREQUAL "YES")
endif ()
# if the return value is !=${TEST_EXPECT} bail out
if (NOT TEST_RESULT EQUAL TEST_EXPECT)
message (FATAL_ERROR "Failed: The output of ${TEST_FOLDER}/${TEST_ONEFILE} did not match ${TEST_FOLDER}/${TEST_TWOFILE}.\n${TEST_ERROR}")
message (STATUS "Failed: The output of ${TEST_FOLDER}/${TEST_ONEFILE} did not match ${TEST_FOLDER}/${TEST_TWOFILE}.\n${TEST_ERROR}")
endif ()
else ()
if (CMAKE_VERSION VERSION_LESS "3.14.0")
message (FATAL_ERROR "CANNOT get file size, file command SIZE not supported")
message (STATUS "CANNOT get file size, file command SIZE not supported")
else ()
file (SIZE ${TEST_FOLDER}/${TEST_ONEFILE} TEST_ONE_SIZE)
file (SIZE ${TEST_FOLDER}/${TEST_TWOFILE} TEST_TWO_SIZE)
Expand All @@ -74,7 +74,7 @@ else ()
elseif (TEST_FUNCTION MATCHES "LTEQ")
if (TEST_ONE_SIZE LESS_EQUAL TEST_TWO_SIZE)
if (CMAKE_VERSION VERSION_GREATER_EQUAL "3.15.0")
message (VERBOSES "Passed: The size of ${TEST_FOLDER}/${TEST_ONEFILE} was less or equal ${TEST_FOLDER}/${TEST_TWOFILE}")
message (VERBOSE "Passed: The size of ${TEST_FOLDER}/${TEST_ONEFILE} was less or equal ${TEST_FOLDER}/${TEST_TWOFILE}")
endif ()
else ()
message (FATAL_ERROR "The size of ${TEST_FOLDER}/${TEST_ONEFILE} was NOT less or equal ${TEST_FOLDER}/${TEST_TWOFILE}")
Expand Down

0 comments on commit f9eedd1

Please sign in to comment.