2021-04-18 18:57:45 +00:00
|
|
|
name: Build
|
|
|
|
|
2023-04-14 08:19:33 +00:00
|
|
|
on:
|
|
|
|
push:
|
|
|
|
pull_request:
|
|
|
|
schedule:
|
|
|
|
- cron: "0 0 * * *"
|
2021-04-18 18:57:45 +00:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
2023-10-27 13:58:17 +00:00
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
|
|
runs-on: ${{ matrix.os }}
|
2021-04-18 18:57:45 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-04-17 08:25:38 +00:00
|
|
|
uses: actions/checkout@v3
|
2021-04-18 18:57:45 +00:00
|
|
|
with:
|
|
|
|
path: example-application
|
|
|
|
|
2023-10-27 13:58:17 +00:00
|
|
|
- name: Set up Python
|
|
|
|
uses: actions/setup-python@v4
|
|
|
|
with:
|
|
|
|
python-version: 3.11
|
|
|
|
|
|
|
|
- name: Setup Zephyr project
|
|
|
|
uses: zephyrproject-rtos/action-zephyr-setup@v1
|
|
|
|
with:
|
|
|
|
app-path: example-application
|
|
|
|
toolchains: arm-zephyr-eabi
|
2021-04-18 18:57:45 +00:00
|
|
|
|
|
|
|
- name: Build firmware
|
|
|
|
working-directory: example-application
|
2023-10-27 13:58:17 +00:00
|
|
|
shell: bash
|
2021-04-18 18:57:45 +00:00
|
|
|
run: |
|
2023-10-27 13:58:17 +00:00
|
|
|
if [ "${{ runner.os }}" = "Windows" ]; then
|
|
|
|
EXTRA_TWISTER_FLAGS="--short-build-path -O/tmp/twister-out"
|
|
|
|
fi
|
|
|
|
west twister -T app -v --inline-logs --integration $EXTRA_TWISTER_FLAGS
|
2021-04-18 18:57:45 +00:00
|
|
|
|
2022-11-19 14:54:27 +00:00
|
|
|
- name: Twister Tests
|
2021-05-21 01:49:09 +00:00
|
|
|
working-directory: example-application
|
2023-10-27 13:58:17 +00:00
|
|
|
shell: bash
|
2021-05-21 01:49:09 +00:00
|
|
|
run: |
|
2023-10-27 13:58:17 +00:00
|
|
|
if [ "${{ runner.os }}" = "Windows" ]; then
|
|
|
|
EXTRA_TWISTER_FLAGS="--short-build-path -O/tmp/twister-out"
|
|
|
|
fi
|
|
|
|
west twister -T tests -v --inline-logs --integration $EXTRA_TWISTER_FLAGS
|