From c6c5f2704bfa2ef592edc3d9b676b4a716c50b54 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mika=C3=ABl=20Capelle?= Date: Sat, 8 Jun 2024 19:18:12 +0200 Subject: [PATCH] Exclude tests from ALL target. (#147) * Exclude tests from ALL target. * Build tests in CI. * Ignore tests failing in the CI. --- .github/workflows/build.yml | 13 +++++++++++++ .github/workflows/linting.yml | 2 ++ tests/CMakeLists.txt | 4 ++-- 3 files changed, 17 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4ebf398c..9d3bc26e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,15 +1,28 @@ name: Build UIBase + on: push: branches: master pull_request: types: [opened, synchronize, reopened] + jobs: build: runs-on: windows-2022 steps: - name: Build UI Base + id: build-uibase uses: ModOrganizer2/build-with-mob-action@master with: mo2-third-parties: gtest spdlog boost mo2-dependencies: cmake_common + - name: Build UI Base Tests + run: cmake --build vsbuild --config RelWithDebInfo -j4 --target uibase-tests + working-directory: ${{ steps.build-uibase.outputs.working-directory }} + + - name: Test UI Base + # there are missing stuffs in the CI currently that fails the test, to be + # investigated + continue-on-error: true + run: ctest --test-dir vsbuild -C RelWithDebInfo --output-on-failure + working-directory: ${{ steps.build-uibase.outputs.working-directory }} diff --git a/.github/workflows/linting.yml b/.github/workflows/linting.yml index fca3605e..67447b21 100644 --- a/.github/workflows/linting.yml +++ b/.github/workflows/linting.yml @@ -1,8 +1,10 @@ name: Lint UIBase + on: push: pull_request: types: [opened, synchronize, reopened] + jobs: lint: runs-on: ubuntu-latest diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 31ca95f1..022cd8ca 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.16) -add_executable(uibase_tests) -mo2_configure_tests(uibase_tests +add_executable(uibase-tests EXCLUDE_FROM_ALL) +mo2_configure_tests(uibase-tests WARNINGS OFF DEPENDS uibase)