neovim/cmake/RunUnittests.cmake
Thiago de Arruda 78fd9386b6 Fix unit tests
Apparently busted 1.11.0 is broken(https://github.com/Olivine-Labs/busted/issues/236)
in a way that is causing the unit tests to fail. This pins the version to 1.10.0
and also fixes a wrong variable set when msgpack was added as a dependency
2014-04-14 16:46:16 -03:00

14 lines
404 B
CMake

get_filename_component(BUSTED_DIR ${BUSTED_PRG} PATH)
set(ENV{PATH} "${BUSTED_DIR}:$ENV{PATH}")
set(ENV{NVIM_TEST_LIB} ${NVIM_TEST_LIB})
set(ENV{TEST_INCLUDES} ${TEST_INCLUDES})
execute_process(
COMMAND ${BUSTED_PRG} -o ${BUSTED_OUTPUT_TYPE} --pattern=.moon ${TEST_DIR}
WORKING_DIRECTORY ${WORKING_DIR}
RESULT_VARIABLE res)
if(NOT res EQUAL 0)
message(FATAL_ERROR "Unit tests failed.")
endif()