@@ -49,104 +49,15 @@ jobs:
4949 name : mpy-cross
5050 path : micropython/mpy-cross/build/mpy-cross
5151
52- unix_coverage :
53- name : unix coverage
54- needs : mpy_cross
55- runs-on : ubuntu-24.04
56- env :
57- PYBRICKS_NO_REDIRECT_STDOUT : 1
58- steps :
59- - name : Checkout repo
60- uses : actions/checkout@v4
61- with :
62- submodules : true
63- - name : Download mpy-cross
64- uses : actions/download-artifact@v4
65- with :
66- name : mpy-cross
67- path : micropython/mpy-cross/build
68- - name : Fix file permission
69- run : chmod +x micropython/mpy-cross/build/mpy-cross
70- - name : Build
71- run : |
72- cd micropython
73- make ${MAKEOPTS} -C ports/unix VARIANT=coverage submodules
74- make ${MAKEOPTS} -C ports/unix VARIANT=coverage deplibs
75- make ${MAKEOPTS} -C ports/unix VARIANT=coverage
76- - name : Test
77- if : ${{ success() }}
78- run : |
79- ulimit -n 1024 # needed for micropython/tests/extmod/select_poll_fd.py
80- cd micropython
81- make -C ports/unix VARIANT=coverage test_full
82- (cd tests && MICROPY_CPYTHON3=python3 MICROPY_MICROPYTHON=../ports/unix/build-coverage/micropython ./run-multitests.py multi_net/*.py)
83- - name : List failed tests
84- if : failure()
85- run : micropython/tests/run-tests.py --print-failures
86-
87- firmware :
88- name : firmware
89- strategy :
90- fail-fast : false
91- matrix :
92- hub : [cityhub, essentialhub, movehub, nxt, primehub, technichub, ev3]
93- needs : [mpy_cross]
94- runs-on : ubuntu-24.04
95- steps :
96- - name : Install cross-compiler
97- run : sudo apt-get update && sudo apt-get install --yes gcc-arm-none-eabi
98- - name : Checkout repo
99- uses : actions/checkout@v4
100- with :
101- submodules : true
102- fetch-depth : 0
103- - name : Download mpy-cross
104- uses : actions/download-artifact@v4
105- with :
106- name : mpy-cross
107- path : micropython/mpy-cross/build
108- - name : Fix file permission
109- run : chmod +x micropython/mpy-cross/build/mpy-cross
110- - run : pipx install poetry
111- - run : poetry install --only=stats
112- - name : Build firmware (pull request)
113- if : ${{ github.base_ref != null }}
114- run : poetry run .github/build-each-commit.py ${{ matrix.hub }} ${{ github.sha }}
115- - name : Build firmware (non-master branch)
116- if : ${{ github.base_ref == null && github.ref != 'refs/heads/master' }}
117- env :
118- STORAGE_ACCOUNT : ${{ secrets.STORAGE_ACCOUNT }}
119- STORAGE_KEY : ${{ secrets.STORAGE_KEY }}
120- STORAGE_URL : ${{ secrets.STORAGE_URL }}
121- FIRMWARE_SIZE_TABLE : ${{ secrets.FIRMWARE_SIZE_TABLE }}
122- run : poetry run .github/build-each-commit.py ${{ matrix.hub }} ${{ github.ref_name }}
123- - name : Build firmware (master branch)
124- if : ${{ github.base_ref == null && github.ref == 'refs/heads/master' }}
125- run : |
126- export MICROPY_GIT_TAG=ci-build-${{ github.run_number }}-$(git describe --tags --dirty --always --exclude "@pybricks/*")
127- export MICROPY_GIT_HASH=$(echo ${{ github.sha }} | cut -c1-8)
128- make -C bricks/${{ matrix.hub }}
129- - name : Extract firmware.zip for upload
130- if : ${{ success()}}
131- working-directory : bricks/${{ matrix.hub }}/build
132- run : unzip firmware.zip -d upload
133- - name : Short hash
134- id : vars
135- run : echo "short_sha=$(echo ${{ github.sha }} | cut -c1-8)" >> $GITHUB_OUTPUT
136- - name : Upload firmware
137- if : ${{ success()}}
138- uses : actions/upload-artifact@v4
139- with :
140- name : ${{ matrix.hub }}-firmware-build-${{ github.run_number }}-git${{ steps.vars.outputs.short_sha }}
141- path : bricks/${{ matrix.hub }}/build/upload/*
142-
14352 virtualhub :
14453 name : virtual hub
14554 needs : [mpy_cross]
14655 runs-on : ubuntu-24.04
14756 steps :
148- - name : Install depedencies
149- run : sudo apt-get update && sudo apt-get install lcov python3-numpy --yes
57+ - name : Install dependencies
58+ run : sudo apt-get update && sudo apt-get install lcov pipx
59+ - name : Install Pybricksdev
60+ run : pipx install pybricksdev
15061 - name : Checkout repo
15162 uses : actions/checkout@v4
15263 with :
@@ -175,39 +86,8 @@ jobs:
17586 flag-name : virtualhub
17687 parallel : true
17788
178- pbio :
179- name : pbio tests
180- runs-on : ubuntu-24.04
181- env :
182- PBIO_TEST_RESULTS_DIR : lib/pbio/test/results
183- steps :
184- - name : Install prerequisites
185- run : |
186- sudo apt-get update
187- sudo apt-get install --yes doxygen graphviz lcov
188- - name : Checkout repo
189- uses : actions/checkout@v4
190- with :
191- submodules : true
192- - name : Build
193- run : |
194- make $MAKEOPTS -C lib/pbio/test
195- - name : Build docs
196- run : |
197- make $MAKEOPTS -C lib/pbio/doc
198- - name : Build coverage
199- run : |
200- make $MAKEOPTS -C lib/pbio/test build-coverage/lcov.info
201- - name : Coveralls
202- uses : coverallsapp/github-action@v2
203- with :
204- github-token : ${{ secrets.GITHUB_TOKEN }}
205- file : lib/pbio/test/build-coverage/lcov.info
206- flag-name : PBIO
207- parallel : true
208-
20989 finish :
210- needs : [virtualhub, pbio ]
90+ needs : [virtualhub]
21191 runs-on : ubuntu-24.04
21292 steps :
21393 - name : Coveralls
0 commit comments