Skip to content

Relearn

Relearn #122

Workflow file for this run

name: CI Tests
on:
push:
branches:
- main
pull_request:
types:
- opened
- reopened
- synchronize
env:
BUILD_DIR: "${{ github.workspace }}/build"
TEST_DIR: "${{ github.workspace }}/tests"
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install dependencies
run: sudo apt-get install -y build-essential gcc-multilib g++-multilib
- name: Install gcovr
run: pip install gcovr
- name: Setup project
run: cmake -S ${TEST_DIR} -B ${BUILD_DIR} -DCMAKE_BUILD_TYPE=Debug
- name: Build
run: cmake --build ${BUILD_DIR}
# - name: Test
# working-directory: build
# run: ctest -V
- name: Test with Coverage
working-directory: build
run: cmake --build ${BUILD_DIR} --target os_test_coverage
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Lint src
uses: jidicula/[email protected]
with:
clang-format-version: "18"
check-path: src
- name: Lint tests
uses: jidicula/[email protected]
with:
clang-format-version: "18"
check-path: tests/src
increment_version:
name: Increment Version
uses: automas-dev/reusable-workflows/.github/workflows/increment_version.yml@main
if: github.ref == 'refs/heads/main'
secrets: inherit
needs: [test, lint]
permissions:
contents: write