feat: Add a way to cfg away test for unsuported peripherals #27
Workflow file for this run
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: HIL | |
on: | |
merge_group: | |
workflow_dispatch: | |
# FIXME: Remove before merging? | |
push: | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
riscv-hil: | |
name: HIL Test | ${{ matrix.target.soc }} | |
runs-on: | |
labels: [self-hosted, "${{ matrix.target.runner }}"] | |
env: | |
PROBE_RS_CHIP: ${{ matrix.target.soc }} | |
CARGO_BUILD_TARGET: ${{ matrix.target.rust-target }} | |
strategy: | |
fail-fast: false | |
matrix: | |
target: | |
- soc: esp32c3 | |
runner: rustboard | |
rust-target: riscv32imc-unknown-none-elf | |
- soc: esp32c6 | |
runner: esp32c6-usb | |
rust-target: riscv32imac-unknown-none-elf | |
- soc: esp32h2 | |
runner: esp32h2-usb | |
rust-target: riscv32imac-unknown-none-elf | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: 'feat/hil-testing' | |
- uses: dtolnay/rust-toolchain@v1 | |
with: | |
target: ${{ env.CARGO_BUILD_TARGET }} | |
toolchain: nightly | |
- name: Run tests | |
run: | | |
cd hil-test/ | |
cargo test --release --features=${{ matrix.target.soc }} | |
# Test Xtensa targets: | |
# TODO: Add jobs for Xtensa once supported by `probe-rs` |