Re: [PATCH v5 15/15] CI: add a "linux-cmake-test" to run cmake & ctest on linux
On Fri, Dec 2, 2022 at 6:28 AM Ævar Arnfjörð Bjarmason <avarab@gmail.com> wrote:
Show 8 quoted lines
> Since [1] the "cmake" build method should work properly on Linux, but
> as seen in preceding commits there were various bugs in it, which are
> hopefully now all fixed.
>
> To ensure that it doesn't break again let's add a "linux-cmake-ctest"
> target to build and test "cmake" on Linux, in addition to that we'll
> also run the tests with "ctest" instead of "make" or "prove", so we
> can assert that testing with that method works..
Show 11 quoted lines
> This also stress tests running "cmake" (and "ctest") out of a build
> directory that isn't the top-level. The "vs-build" job uses "cmake"
> since [2], but clobbers the top-level "Makefile" and builds in the
> top-level directory.
>
> That was the reason for why we didn't spot that various tests still
> required missing "mergetools/*" etc, which was fixed by using
> "$GIT_SOURCE_DIR" in a preceding commit.
>
> Since the "ci/lib.sh" already creates and exports a
> GIT_TEST_OPTS="..." we'll pick that up in our CI, see the preceding
Probably want: s/CI,/CI;/
Show 11 quoted lines
> commit. Because we pass the "--verbose-log -x
> --github-workflow-markup" in the GitHub CI as a result the interaction
> with "handle_failed_tests" here works correctly. I.e. on failure we'll
> have saved "t/test-results/*.{exit,out,markup}" files relevant to the
> failing test(s).
>
> 1. f31b6244950 (Merge branch 'yw/cmake-updates', 2022-06-07)
> 2. 4c2c38e800f (ci: modification of main.yml to use cmake for vs-build
> job, 2020-06-26)
>
> Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>