I would look at use the FIXTURES features to define the file as a shared resource. Here is a good article on how to use this feature:
https://crascit.com/2016/10/18/test-fixtures-with-cmake-ctest/ On Wed, Aug 1, 2018 at 12:32 AM Quang Ha <quang.t.ha...@gmail.com> wrote: > > Hi all, > > Is there a way to let ctest create an output file after a certain test? Say I > want to run test 1 (name "run_simulation"), which is a simulation and should > produce an output file containing numerical results. I then want to compare > it against analytical results in test 2 (name "compare_results")? > > Thanks, > QT > -- > > Powered by www.kitware.com > > Please keep messages on-topic and check the CMake FAQ at: > http://www.cmake.org/Wiki/CMake_FAQ > > Kitware offers various services to support the CMake community. For more > information on each offering, please visit: > > CMake Support: http://cmake.org/cmake/help/support.html > CMake Consulting: http://cmake.org/cmake/help/consulting.html > CMake Training Courses: http://cmake.org/cmake/help/training.html > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > https://cmake.org/mailman/listinfo/cmake -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: https://cmake.org/mailman/listinfo/cmake