From f320b263e1b82d9ff67dd96efb1999248f8fd867 Mon Sep 17 00:00:00 2001 From: AlexisDanlos Date: Sun, 1 Mar 2026 21:31:11 +0100 Subject: [PATCH 1/2] ci: enhance testing workflow with build tools and Python syntax validation --- .github/workflows/release.yml | 54 +++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4716763..15e028f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,7 +10,61 @@ env: MINGW_ROOT: /usr/x86_64-w64-mingw32/sys-root/mingw jobs: + test: + runs-on: ubuntu-latest + container: + image: fedora:41 + + steps: + - name: Install build tools and test dependencies + run: | + dnf install -y git gcc-c++ libsamplerate-devel python3 + + - name: Checkout repository + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Fix git ownership + run: git config --global --add safe.directory "$GITHUB_WORKSPACE" + + - name: Compile ring buffer tests + run: | + g++ -std=c++17 -pthread \ + tests/test_ring_buffer.cpp \ + -I include/ \ + -o tests/test_ring_buffer + + - name: Run ring buffer tests + timeout-minutes: 2 + run: ./tests/test_ring_buffer + + - name: Compile resampler quality tests + run: | + g++ -std=c++17 \ + tests/test_resampler_quality.cpp \ + src/audio/Resampler.cpp \ + -I include/ \ + -lsamplerate \ + -DHAVE_LIBSAMPLERATE \ + -o tests/test_resampler_quality + + - name: Run resampler quality tests + run: ./tests/test_resampler_quality + + - name: Validate Python plugin syntax + run: | + echo "Checking Python plugin files for syntax errors..." + python3 -m py_compile plugins_py/nda_py_utils/__init__.py + python3 -m py_compile plugins_py/nda_py_utils/audio_ring_buffer.py + python3 -m py_compile plugins_py/examples/passthrough.py + python3 -m py_compile plugins_py/examples/simple_gain.py + python3 -m py_compile plugins_py/examples/fernet_encryptor.py + python3 -m py_compile plugins_py/examples/fernet_decryptor.py + echo "All Python plugin files pass syntax check" + build-windows: + needs: test runs-on: ubuntu-latest container: image: fedora:41 From f2ebc18db4210dfd6504884eead512ec5d9885a3 Mon Sep 17 00:00:00 2001 From: AlexisDanlos Date: Sun, 1 Mar 2026 21:34:12 +0100 Subject: [PATCH 2/2] ci: update branch filter to allow all branches for release workflow --- .github/workflows/release.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 15e028f..4284438 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -2,7 +2,7 @@ name: Windows Release on: push: - branches: [main] + branches: ['**'] tags: - 'v*' @@ -65,6 +65,7 @@ jobs: build-windows: needs: test + if: github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/v') runs-on: ubuntu-latest container: image: fedora:41