소스 검색

ENH: CI: Indicate failure when tests fail

Indicate failure in the test driver script if ctest_test fails, i.e. if
tests fail. This ensures that test failures propagate up to the script
that runs ctest.
Max Smolens 7 년 전
부모
커밋
b7ce5be3d3
1개의 변경된 파일8개의 추가작업 그리고 1개의 파일을 삭제
  1. 8 1
      CMake/CircleCI/CircleCI_CTK_Docker.cmake

+ 8 - 1
CMake/CircleCI/CircleCI_CTK_Docker.cmake

@@ -85,6 +85,13 @@ ctest_configure(
 
 ctest_build( BUILD ${CTK_BINARY_DIR} )
 
-ctest_test( BUILD ${CTEST_BINARY_DIRECTORY} )
+ctest_test(
+  BUILD ${CTEST_BINARY_DIRECTORY}
+  RETURN_VALUE result
+  )
 
 ctest_submit()
+
+if(result)
+  message(FATAL_ERROR "ERROR: Tests failed")
+endif()