Files
torlando-tech a135c761e6 chore(greptile): iter 1 — applied 4 (3 ACCEPT + 1 MODIFY), rejected 1
Greptile review feedback on PR #21:

ACCEPT:
- test_patch_nimble.py:151 (P1) — replace dead `if False else True`
  ternary with a real assertion that "already applied" is absent on
  the first run.
- test_patch_nimble.py:247 (P1) — invoke the shim subprocess via
  `sys.executable` instead of hardcoded `/usr/bin/python3` so CI's
  setup-python interpreter is used consistently.
- workflows/test.yml:50 (P2) — include hash of
  deps/microReticulum/platformio.ini in PlatformIO cache key so the
  cache invalidates when dependencies change.

MODIFY (narrowed):
- test_ring_buffers.cpp:209 (P2) — keep both `write(data, 0)` and
  `write(data, -1)` assertions, but add a comment clarifying that
  EncodedRingBuffer::write() takes signed `int length` (not size_t),
  so -1 hits the `length <= 0` branch — same as 0. Greptile's
  premise (size_t wrap to SIZE_MAX) does not apply to this codebase.
  The two assertions lock the contract in case the param is ever
  migrated to size_t.

REJECT (silently — no public reply per agent policy):
- test_audio_filters.cpp:237 (P1) — VoiceFilterChain::process()
  takes `numSamples = frames * channels` per the documented
  contract in audio_filters.h:33-40, and the implementation does
  `numFrames = numSamples / channels_` (audio_filters.cpp:63). The
  multichannel test correctly passes `(int)samples.size() = 8000`
  (4000 frames * 2 channels). No out-of-bounds read occurs.
2026-05-04 15:43:14 -04:00

77 lines
2.2 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: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install pytest
run: pip install pytest
- name: Run pytest
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