runtest.cmake 593 B

12345678910111213141516
  1. # Should be used to run ctest
  2. #
  3. # example usage:
  4. # cmake -DETH_TEST_NAME=TestInterfaceStub -DCTEST_COMMAND=/path/to/ctest -P scripts/runtest.cmake
  5. if (NOT CTEST_COMMAND)
  6. message(FATAL_ERROR "ctest could not be found!")
  7. endif()
  8. # verbosity is off, cause BOOST_MESSAGE is not thread safe and output is a trash
  9. # see https://codecrafter.wordpress.com/2012/11/01/c-unit-test-framework-adapter-part-3/
  10. #
  11. # output might not be usefull cause of thread safety issue
  12. execute_process(COMMAND ${CTEST_COMMAND} --force-new-ctest-process -C Debug --output-on-failure -j 4 -R "${ETH_TEST_NAME}[.].*")