Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
preset:
description: >
CMake preset to build the project, run
`cmake --build --list-presets` to see options
`cmake --list-presets` to see options
required: false
type: string
default: 'nucleo-debug'
Expand All @@ -20,7 +20,7 @@ on:
preset:
description: >
CMake preset to build the project, run
`cmake --build --list-presets` to see options
`cmake --list-presets` to see options
required: false
type: string
default: 'nucleo-debug'
Expand All @@ -43,7 +43,7 @@ jobs:
submodules: false
fetch-depth: 1

- name: Init submodules\
- name: Init submodules
run: |
git config --global --add safe.directory '*'
./tools/init-submodules.sh
Expand All @@ -63,4 +63,4 @@ jobs:
path: out/build/${{ inputs.preset }}/libst-lib.a
retention-days: 7
compression-level: 0
if-no-files-found: error
if-no-files-found: error
9 changes: 6 additions & 3 deletions .github/workflows/compile-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,12 @@ jobs:
- board-debug
- board-release
- board-relwithdebinfo
- board-debug-eth
- board-release-eth
- board-relwithdebinfo-eth
- board-debug-eth-ksz8041
- board-debug-eth-lan8700
- board-release-eth-ksz8041
- board-release-eth-lan8700
- board-relwithdebinfo-eth-ksz8041
- board-relwithdebinfo-eth-lan8700
# - simulator
fail-fast: false
uses: ./.github/workflows/build.yml
Expand Down
28 changes: 25 additions & 3 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,14 @@ on:
pull_request:
branches: [ development ]

concurrency:
group: tests-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
tests:
runs-on: ubuntu-latest
timeout-minutes: 30

steps:
- name: Checkout repository
Expand All @@ -17,16 +22,33 @@ jobs:
run: |
sudo apt-get update
sudo apt-get install -y cmake ninja-build build-essential

- name: Cache simulator deps
uses: actions/cache@v4
with:
path: out/build/simulator/_deps
key: simulator-deps-${{ runner.os }}-${{ hashFiles('CMakeLists.txt', 'Tests/CMakeLists.txt') }}
restore-keys: |
simulator-deps-${{ runner.os }}-

- name: Configure (CMake)
run: |
cmake --preset simulator
cmake -S . -B out/build/simulator -G Ninja -DCMAKE_BUILD_TYPE=Debug

- name: Build
run: |
cmake --build out/build/simulator

- name: Run tests (ctest)
working-directory: out/build/simulator
run: |
ctest --output-on-failure
ctest --test-dir out/build/simulator --no-tests=error --output-on-failure

- name: Upload test reports
if: always()
uses: actions/upload-artifact@v4
with:
name: simulator-test-reports
path: |
out/build/simulator/Testing/Temporary/LastTest.log
retention-days: 7
if-no-files-found: ignore
Loading