Warning, /acts/Detray/tests/integration_tests/io/CMakeLists.txt is written in an unsupported language. File is not indexed.
0001 # This file is part of the ACTS project.
0002 #
0003 # Copyright (C) 2016 CERN for the benefit of the ACTS project
0004 #
0005 # This Source Code Form is subject to the terms of the Mozilla Public
0006 # License, v. 2.0. If a copy of the MPL was not distributed with this
0007 # file, You can obtain one at https://mozilla.org/MPL/2.0/.
0008
0009 # Helper function for running a test in a specific directory.
0010 function(_run_test_in_dir test dir)
0011 # Make the directory.
0012 file(MAKE_DIRECTORY "${dir}")
0013 # Run the test in that directory.
0014 set_tests_properties(
0015 "detray_integration_test_${test}"
0016 PROPERTIES WORKING_DIRECTORY "${dir}"
0017 )
0018 endfunction()
0019
0020 detray_add_integration_test( io_roundtrip
0021 "io_json_detector_roundtrip.cpp"
0022 LINK_LIBRARIES GTest::gtest_main vecmem::core detray::core_array
0023 detray::io_array detray::test_common detray::test_cpu
0024 )
0025
0026 # Run integration tests only after unit tests passed
0027 set_tests_properties(
0028 detray_integration_test_io_roundtrip
0029 PROPERTIES DEPENDS "detray_unit_test_io_payloads;detray_unit_test_io_writer"
0030 )
0031
0032 _run_test_in_dir( io_roundtrip
0033 "${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/io_roundtrip_test_rundir"
0034 )