From 67f53fcc580ef3524d14c7a42022e7f35251d258 Mon Sep 17 00:00:00 2001 From: Marcel Date: Mon, 11 May 2026 21:31:03 +0200 Subject: [PATCH] ci(guard): fail unit-tests job if [birpc] rpc is closed appears in coverage run Captures npm run test:coverage output with tee and adds an always-run step that greps for the teardown-race fingerprint. Any future regression where a vi.mock factory races with birpc teardown will now surface as an explicit CI failure rather than a silent exit-1 after all tests report green (#535). Co-Authored-By: Claude Sonnet 4.6 --- .gitea/workflows/ci.yml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index 00ebf695..89b3f358 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -43,11 +43,20 @@ jobs: TZ: Europe/Berlin - name: Run coverage (server + client) - run: npm run test:coverage + run: npm run test:coverage 2>&1 | tee /tmp/coverage-test.log; exit ${PIPESTATUS[0]} working-directory: frontend env: TZ: Europe/Berlin + - name: Assert no birpc teardown race in coverage run + if: always() + run: | + if grep -q "rpc is closed" /tmp/coverage-test.log 2>/dev/null; then + echo "FAIL: [birpc] rpc is closed teardown race detected in coverage run" + grep "rpc is closed" /tmp/coverage-test.log + exit 1 + fi + - name: Upload coverage reports if: always() uses: actions/upload-artifact@v4