mirror of
https://github.com/torlando-tech/pyxis.git
synced 2026-09-09 22:45:34 +00:00
104 lines
3.4 KiB
YAML
104 lines
3.4 KiB
YAML
name: Test
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
pyxis-pytest:
|
|
name: Pyxis pytest suite (build_scripts + native)
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
with:
|
|
submodules: recursive
|
|
|
|
- name: Checkout pinned microReticulum reference
|
|
uses: actions/checkout@v4
|
|
with:
|
|
repository: torlando-tech/microReticulum
|
|
ref: cd0338e7fc07d3a7785a450656ba766491cbf6e8
|
|
path: .ci/microReticulum
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v5
|
|
with:
|
|
python-version: '3.11'
|
|
|
|
- name: Install test dependencies
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install -y libbz2-dev
|
|
pip install pytest platformio rns==1.4.2 nomadnet==1.2.8
|
|
|
|
- name: Resolve and attest pinned LVGL dependency
|
|
env:
|
|
PYXIS_PLATFORMIO_BIN: ${{ env.pythonLocation }}/bin/pio
|
|
run: python tools/resolve_lvgl.py --root "$PWD"
|
|
|
|
- name: Build NomadNet real-peer client
|
|
run: |
|
|
cmake -S tests/native/nomadnet_x86_flow \
|
|
-B build/nomadnet-x86-flow \
|
|
-DRNS_SOURCE="$PWD/.ci/microReticulum"
|
|
cmake --build build/nomadnet-x86-flow --parallel
|
|
|
|
- name: Run pytest
|
|
env:
|
|
PYXIS_PLATFORMIO_BIN: ${{ env.pythonLocation }}/bin/pio
|
|
PYXIS_NOMADNET_X86_CLIENT: ${{ github.workspace }}/build/nomadnet-x86-flow/pyxis_nomadnet_x86_flow
|
|
PYXIS_NOMADNET_RNS_PYTHON: ${{ env.pythonLocation }}/bin/python
|
|
PYXIS_NOMADNET_REFERENCE_SOURCE: ${{ env.pythonLocation }}/lib/python3.11/site-packages
|
|
run: pytest tests/build_scripts tests/native -v
|
|
|
|
microreticulum-native:
|
|
name: microReticulum native unit tests (PlatformIO native17)
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
with:
|
|
submodules: recursive
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v5
|
|
with:
|
|
python-version: '3.11'
|
|
|
|
- name: Cache PlatformIO
|
|
uses: actions/cache@v4
|
|
with:
|
|
path: |
|
|
~/.cache/pip
|
|
~/.platformio/.cache
|
|
key: ${{ runner.os }}-pio-mrn-${{ hashFiles('deps/microReticulum/platformio.ini') }}
|
|
|
|
- name: Install PlatformIO
|
|
run: pip install --upgrade platformio
|
|
|
|
# microReticulum native17 vendors libbz2 sources but link_bz2.py
|
|
# links against system libbz2 — needs libbz2-dev on Ubuntu.
|
|
- name: Install libbz2-dev
|
|
run: sudo apt-get install -y libbz2-dev
|
|
|
|
# Run only suites that build cleanly under native17 in the fork.
|
|
# Erroring suites (test_ble, test_tdeck, test_lxmf, test_ratchets, etc.)
|
|
# are tracked separately — see pyxis MEMORY.md.
|
|
- name: Run native17 tests
|
|
working-directory: deps/microReticulum
|
|
run: |
|
|
pio test -e native17 -f test_os
|
|
pio test -e native17 -f test_bytes
|
|
pio test -e native17 -f test_msgpack
|
|
pio test -e native17 -f test_crypto
|
|
pio test -e native17 -f test_filesystem
|
|
pio test -e native17 -f test_objects
|
|
pio test -e native17 -f test_general
|
|
pio test -e native17 -f test_reference
|
|
pio test -e native17 -f test_example
|
|
pio test -e native17 -f test_collections
|
|
pio test -e native17 -f test_interop
|