Daily Test Workflow #3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Daily Test Workflow | |
on: | |
workflow_dispatch: | |
# push: | |
# branches: [main, develop] | |
# pull_request: | |
# branches: [main, develop] | |
# on: workflow_dispatch | |
jobs: | |
formatting-check: | |
name: Formatting Check | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
path: | |
- check: 'src' | |
exclude: '' # Nothing to exclude | |
- check: 'test' | |
exclude: '(template|unity|hw_test)' # Exclude file paths containing "template" or "unity" | |
steps: | |
- uses: actions/checkout@v4.1.7 | |
- name: Run clang-format style check for C/C++/Protobuf programs. | |
uses: jidicula/clang-format-action@v4.13.0 | |
with: | |
clang-format-version: '17' | |
check-path: ${{ matrix.path['check'] }} | |
exclude-regex: ${{ matrix.path['exclude'] }} | |
# fallback-style: 'Microsoft' # optional | |
- name: Annotate lines with clang-format errors | |
uses: yuzutech/annotations-action@v0.5.0 | |
with: | |
repo-token: "${{ secrets.GITHUB_TOKEN }}" | |
title: 'Results of CppCheck src files' | |
input: 'annotations.json' | |
build: | |
needs: formatting-check | |
name: Template Test RUN | |
runs-on: windows-latest | |
# strategy: | |
# matrix: | |
# os: [ubuntu-latest, windows-latest] | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4.1.1 | |
with: | |
submodules: recursive | |
- name: arm-none-eabi-gcc | |
uses: ryanwinter/arm-none-eabi-gcc@master | |
with: | |
release: '10-2021.10' | |
- name: Install Ninja | |
uses: seanmiddleditch/gha-setup-ninja@v3 | |
- name: Build binary | |
working-directory: test/template | |
run: | | |
mkdir out | |
cmake -Bout -GNinja | |
cmake --build out | |
- name: List files | |
working-directory: test/template/out | |
run: dir | |
- name: Run template tests | |
working-directory: test/template/out | |
run: ./template_test.exe -v | |
- name: Annotate Failled tests | |
uses: yuzutech/annotations-action@v0.5.0 | |
with: | |
repo-token: "${{ secrets.GITHUB_TOKEN }}" | |
title: 'Results of CppCheck src files' | |
input: 'annotations.json' |