Closed jelin-sh closed 1 year ago
Fixes #1180
This one needs to be reverted.
I changed this, because no tests were run in CI. (#1170)
This PR reverts that all again. See https://github.com/jbeder/yaml-cpp/actions/runs/4480153307/jobs/7877729295?pr=1181#step:6:17 No tests were found!!!
So I suggest to revert this PR. And after it, @skjsnb can think about a different solution.
I don't see why the solution before this PR was an issue to any one. As it checks for YAML_CPP_BUILD_TESTS
before including the test sub dir.
Reverted, thanks for noticing. Open to any suggestions.
@MatthijsBurgh I'm sorry for causing trouble to you. I indeed didn't think about the part concerning the CI process, so I agree with your opinion.
@jbeder thanks for the quick response
If
CTest
is a global reference, thenYAML_CPP_BUILD_TESTS
will be called and the compilation product will be generated regardless of whetherYAML_CPP_BUILD_TESTS
is enabled or not. So it makes more sense to putinclude(CTest)
inside theif (YAML_CPP_BUILD_TESTS)
statement.1180