@@ -27,6 +27,7 @@ OPTION(BUILD_PYTHON_CLIENT "Build python client" TRUE)
2727OPTION (BUILD_TESTS "Build Tests" TRUE )
2828OPTION (BUILD_WEB_SERVER "Build DataFed Web Server" TRUE )
2929OPTION (ENABLE_UNIT_TESTS "Enable unit tests" TRUE )
30+ OPTION (ENABLE_INTEGRATION_TESTS "Enable integration tests" TRUE )
3031OPTION (ENABLE_MEMORY_TESTS "Enable memory tests" FALSE )
3132OPTION (BUILD_SHARED_LIBS "By default DataFed tries to build static libraries
3233with the exception of libdatafed-authz which must always be a shared library,
@@ -79,7 +80,6 @@ endif()
7980
8081if (NOT DEFINED DATAFED_DOMAIN)
8182 get_value_from_datafed_sh("DATAFED_DOMAIN" DATAFED_DOMAIN)
82- message ("TESTING: DATAFED_DOMAIN : ${DATAFED_DOMAIN} " )
8383endif ()
8484
8585if (NOT DEFINED DATAFED_DEPENDENCIES_INSTALL_PATH)
@@ -188,6 +188,12 @@ if( BUILD_FOXX OR BUILD_CORE_SERVER )
188188 add_subdirectory ( core )
189189endif ()
190190
191+ # Must occur before building authz, location of mock keys are defined here
192+ # ENV DATAFED_MOCK_CORE_PUB_KEY
193+ if (ENABLE_INTEGRATION_TESTS OR ENABLE_END_TO_END_TESTS)
194+ add_subdirectory (tests)
195+ endif ()
196+
191197if ( BUILD_REPO_SERVER OR BUILD_AUTHZ)
192198 add_subdirectory ( repository )
193199endif ()
@@ -241,26 +247,6 @@ if( INSTALL_FOXX )
241247 )
242248endif ()
243249
244- if (ENABLE_END_TO_END_TESTS)
245- if (NOT ENABLE_END_TO_END_API_TESTS AND NOT ENABLE_END_TO_END_WEB_TESTS)
246- message (FATAL_ERROR "Cannot run end-to-end tests because one of the ENABLE_END_TO_END web or API flag is not on" )
247- else ()
248- add_subdirectory (tests/end -to-end )
249- add_subdirectory (tests/end -to-end /web-UI)
250- endif ()
251- else ()
252- if (ENABLE_END_TO_END_API_TESTS)
253- if (BUILD_PYTHON_CLIENT)
254- add_subdirectory (tests/end -to-end )
255- else ()
256- message (FATAL_ERROR "Cannot run end-to-end tests because BUILD_PYTHON_CLIENT is not on" )
257- endif ()
258- endif ()
259- if (ENABLE_END_TO_END_WEB_TESTS)
260- add_subdirectory (tests/end -to-end /web-UI)
261- endif ()
262- endif ()
263-
264250find_library (SODIUM NAMES libsodium.a PATHS ${DEPENDENCY_INSTALL_PATH} /lib)
265251
266252# This is not needed but it is used by zmq I think so we want to print what is found locally just in case
0 commit comments