on xenial help sign in
Add NO_TESTS cmake option to skip tests and therefore speed up builds
daa5708Daniel d'Andrada
CMakeLists.txt+10−5
@@ -98,10 +98,6 @@ add_definitions(-DQT_NO_KEYWORDS)
98# Save a few container detach and conversions
98# Save a few container detach and conversions
99add_definitions(-DQT_STRICT_ITERATORS)
99add_definitions(-DQT_STRICT_ITERATORS)
100
100
101−# Tests
102−include(CTest)
103−enable_testing()
104−
105# Autopilot tests
101# Autopilot tests
106include(autopilot)
102include(autopilot)
107declare_autopilot_test(shell unity8.shell ${CMAKE_SOURCE_DIR}/tests/autopilot/)
103declare_autopilot_test(shell unity8.shell ${CMAKE_SOURCE_DIR}/tests/autopilot/)
@@ -121,7 +117,16 @@ add_subdirectory(libs)
121add_subdirectory(src)
117add_subdirectory(src)
122add_subdirectory(tools)
118add_subdirectory(tools)
123add_subdirectory(qml)
119add_subdirectory(qml)
120+
121+# Tests
122+if (NOT NO_TESTS)
123+ include(CTest)
124+ enable_testing()
124−add_subdirectory(tests)
125+ add_subdirectory(tests)
126+else()
127+ message(STATUS "Tests disabled")
128+endif()
129+
125add_subdirectory(plugins)
130add_subdirectory(plugins)
126
131
127#
132#