Skip to content

cmake: Avoid adding test targets if not top-level #38

cmake: Avoid adding test targets if not top-level

cmake: Avoid adding test targets if not top-level #38

Workflow file for this run

name: Build
on:
push:
workflow_dispatch:
env:
BUILD_CONFIG: Debug
BUILD_DIR: build
jobs:
test:
strategy:
fail-fast: false
matrix:
include:
- name: linux
os: ubuntu-latest
generator: "Unix Makefiles"
- name: macOS
os: macos-latest
generator: "Xcode"
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: "Build and test"
shell: bash
env:
GENERATOR: ${{ matrix.generator }}
run: |
ctest --build-and-test . ./build_$OSTYPE --build-generator "${{ matrix.generator }}" --test-command ctest -C ${{ env.BUILD_CONFIG }} --verbose