diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index a36043e327..ff3fefdafe 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -1,19 +1,26 @@ cmake_minimum_required(VERSION 3.5) # JS AUTOMATED TESTS +option(ENABLE_AUTOMATED_TESTS "Enable JS Automated Tests" ON) -# Set build path as CMAKE CACHE variable to use in tests -set(SCOPY_BUILD_PATH ${CMAKE_BINARY_DIR} CACHE STRING "SCOPY_BUILD_PATH" FORCE) +if(ENABLE_AUTOMATED_TESTS) + # Set build path as CMAKE CACHE variable to use in tests + set(SCOPY_BUILD_PATH ${CMAKE_BINARY_DIR} CACHE STRING "SCOPY_BUILD_PATH" FORCE) -# SCOPY GENERIC TESTS -add_test(NAME "ScopyDefaultJSTests" COMMAND bash ${CMAKE_SOURCE_DIR}/JS/test.sh "${CMAKE_SOURCE_DIR}/resources/emuXml/" - "${CMAKE_SOURCE_DIR}/JS/scopyDefaultTests.js" -) + # SCOPY GENERIC TESTS + add_test(NAME "ScopyDefaultJSTests" + COMMAND bash ${CMAKE_SOURCE_DIR}/JS/test.sh "${CMAKE_SOURCE_DIR}/resources/emuXml/" + "${CMAKE_SOURCE_DIR}/JS/scopyDefaultTests.js" + ) -# PLUGIN SPECIFIC TESTS + # PLUGIN SPECIFIC TESTS -# DATALOGGER -add_test(NAME "DataloggerLogAndLoadJSTests" - COMMAND bash ${CMAKE_SOURCE_DIR}/JS/test.sh "${CMAKE_SOURCE_DIR}/resources/emuXml/" - "${CMAKE_SOURCE_DIR}/plugins/datalogger/JS/dataLoggerAutomatedTest.js" -) + # DATALOGGER + if(ENABLE_PLUGIN_DATALOGGER) + add_test(NAME "DataloggerLogAndLoadJSTests" + COMMAND bash ${CMAKE_SOURCE_DIR}/JS/test.sh "${CMAKE_SOURCE_DIR}/resources/emuXml/" + "${CMAKE_SOURCE_DIR}/plugins/datalogger/JS/dataLoggerAutomatedTest.js" + ) + endif() + +endif()