-
Notifications
You must be signed in to change notification settings - Fork 47
39 lines (39 loc) · 1.41 KB
/
ci-micropython.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: Test MicroPython Releases
on:
push:
pull_request:
branches: [main]
jobs:
test-micropython:
name: Micropython ${{ matrix.micropython_version }}
runs-on: ubuntu-latest
strategy:
matrix:
micropython_version:
- 20210618-v1.16
- 20210902-v1.17
- 20220117-v1.18
- 20220618-v1.19.1
- 20230426-v1.20.0
- 20231005-v1.21.0
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install packages
run: npm ci
- name: Install Python requirements
run: cd test && pip install -r requirements.txt
- name: Download Micropython
run: curl -o micropython.uf2 "https://micropython.org/resources/firmware/RPI_PICO-${VERSION}.uf2"
env:
VERSION: ${{ matrix.micropython_version }}
- name: Create filesystem
run: python test/mklittlefs.py littlefs.img test/micropython/main.py
- name: Test Micropython
run: timeout 10 npm run start:micropython -- --image micropython.uf2 --expect-text "Hello, MicroPython!"
- name: Create SPI test filesystem
run: python test/mklittlefs.py littlefs-spi.img test/micropython/main-spi.py
- name: Test Micropython SPI
run: timeout 10 npm run test:micropython-spi -- "hello world" "h" "0123456789abcdef0123456789abcdef0123456789abcdef"