aboutsummaryrefslogtreecommitdiff
path: root/test/CMakeLists.txt
blob: 6a46dc9bf6a8cc3ec8ec0a4cee93777fedcaf717 (plain)
  1. # To get verbose output: cmake --build build --target "test" -- ARGS='-V'
  2. set(PYTHON python)
  3. if (WIN32)
  4. file(TO_NATIVE_PATH ${CMAKE_BINARY_DIR}/src WIN_DLL_DIR)
  5. set_tests_properties(api_test PROPERTIES
  6. ENVIRONMENT "PATH=${WIN_DLL_DIR};$ENV{PATH}"
  7. )
  8. endif(WIN32)
  9. add_test(html_normalization
  10. ${PYTHON} "-m" "doctest"
  11. "${CMAKE_CURRENT_SOURCE_DIR}/normalize.py"
  12. )
  13. add_test(spectest_library
  14. ${PYTHON} "${CMAKE_CURRENT_SOURCE_DIR}/spec_tests.py" "--no-normalize" "--spec"
  15. "${CMAKE_SOURCE_DIR}/spec.txt" "--library-dir" "${CMAKE_BINARY_DIR}/src"
  16. )
  17. add_test(pathological_tests_library
  18. ${PYTHON} "${CMAKE_CURRENT_SOURCE_DIR}/pathological_tests.py"
  19. "--library-dir" "${CMAKE_BINARY_DIR}/src"
  20. )
  21. add_test(NAME api_test COMMAND api_test)
  22. add_test(spectest_executable
  23. ${PYTHON} "${CMAKE_CURRENT_SOURCE_DIR}/spec_tests.py" "--no-normalize" "--spec" "${CMAKE_SOURCE_DIR}/spec.txt" "--program" "${CMAKE_BINARY_DIR}/src/cmark"
  24. )