MXS-1300: Add basic maxctrl tests

Added basic tests for maxctrl. They simply test that the diagnostic
commands work.
This commit is contained in:
Markus Mäkelä
2017-07-14 16:39:44 +03:00
parent d938dcc701
commit 738dc48df7
5 changed files with 76 additions and 2 deletions

View File

@ -6,6 +6,14 @@ if (NPM_FOUND)
WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
add_custom_target(maxctrl ALL DEPENDS ${CMAKE_BINARY_DIR}/maxctrl/maxctrl)
install_script(${CMAKE_BINARY_DIR}/maxctrl/maxctrl core)
add_custom_target(test_maxctrl
COMMAND ${CMAKE_SOURCE_DIR}/test/run_npm_test.sh
${CMAKE_SOURCE_DIR} # Path to MaxScale sources
${CMAKE_CURRENT_SOURCE_DIR} # Path to test sources
${CMAKE_BINARY_DIR}/maxctrl-test/ # Location where tests are built and run
WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
else()
message(STATUS "Not building MaxCtrl: npm not found")
endif()