Files
charge-controller-firmware/.github/workflows/zephyr.yml
T
Martin JägerandClaude Opus 5.5 b271dc0aba tests: drivers: build half-bridge tests for STM32 boards and run in CI
Add a build-only twister scenario for boards using the STM32 TIM and
HRTIM half-bridge drivers. The tests are not run on hardware, as they
would switch the power stage.

The driver tests are run in CI with:

    west twister -T tests/drivers --integration

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-20 21:11:42 +02:00

59 lines
1.5 KiB
YAML

name: Build firmware
on:
push:
pull_request:
jobs:
build:
# Avoid running twice if pushing to a PR branch in the base repo
if: >
github.event_name != 'pull_request' ||
github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
runs-on: ubuntu-latest
defaults:
run:
working-directory: firmware
steps:
- name: Checkout
uses: actions/checkout@v6
with:
path: firmware
fetch-depth: 0 # necessary to get tags
- name: Python setup
uses: actions/setup-python@v6
with:
python-version: 3.12
- name: Zephyr project setup
uses: zephyrproject-rtos/action-zephyr-setup@v1
with:
app-path: firmware
toolchains: arm-zephyr-eabi
- name: Coding style check
run: |
sudo apt-get update
sudo apt-get install -y clang-format-15 colordiff
git status
bash scripts/check-style.sh
- name: Build firmware
run: |
west build -b mppt_1210_hus app -p
west build -b mppt_2420_hc app -p
west build -b mppt_2420_hpx app -p
west build -b mppt_2420_lc app -p
west build -b mppt_2420_rc app -p
west build -b nucleo_g474re app -p
west build -b pwm_2420_lus app -p
- name: Run tests
run: |
west build -b native_sim -t run tests -p
- name: Run driver tests
run: |
west twister -T tests/drivers --integration --inline-logs