Disable unit test building by default
What
This MR adds a new build flag, BUILD_TESTS
, which is set to OFF
by default. In the default build of YARR, then, nothing under src/tests will be built. Additionally, the executables that are also acting as CI/CD tests located under src/tools have been renamed to match the test naming convention ("test_" prefix) and these are also excluded from the build by default.
By setting BUILD_TESTS
to ON
during the build, everything is built as before:
$ cmake -DBUILD_TESTS=on ..
This MR updates the file names and build options in .gitlab-ci.yml accordingly.
Future Ideas
Consider making the unit tests located under src/tools (e.g. test_json
(was testJson
before this MR)), unit tests in the form required by Catch2 and place under the src/tests directory.