Skip to content

ci: run every non-browser test suite in the unit gate - #77

Closed
matej21 wants to merge 1 commit into
mainfrom
fix/ci-test-coverage
Closed

ci: run every non-browser test suite in the unit gate#77
matej21 wants to merge 1 commit into
mainfrom
fix/ci-test-coverage

Conversation

@matej21

@matej21 matej21 commented Aug 20, 2026

Copy link
Copy Markdown
Member

The gap

bun run test — the command CI's Unit & Integration Tests job runs — enumerated the directories it covered:

bun test tests/unit tests/react tests/cases tests/*.test.ts tests/*.test.tsx

Everything outside that list was invisible to CI. On main that is 20 test files / 206 tests:

directory files
packages/bindx-form/tests 6
packages/bindx-uploader/tests 6
packages/bindx-generator/tests 4
tests/bindx-client 3
tests/repeater 2

This is not hypothetical. The has-many materialisation bug fixed in #76 was a failing test in packages/bindx-form/tests/formRelations.test.tsx, and the board stayed green over it.

The fix

Invert the selection: run everything, exclude only tests/browser (which needs a live playground and has its own test:browser job).

"test": "bun test --path-ignore-patterns='**/tests/browser/**'"

An allow-list drifts every time someone adds a directory — that is exactly how this happened. An ignore pattern covers new test directories by default.

test:all is dropped: it now differs from test only by also running tests/browser, so it fails for anyone without a playground running.

Verification

Full gate run locally under a CPU lease, on this branch:

files tests fail
before 129 1531 0
after 149 1737 0

No test needed fixing — the newly covered suites were already green once #76 landed.

What this does not cover

tests/browser is still gated separately by the Browser Tests job, unchanged.

`bun run test` enumerated the directories it covered, so 20 test files
never ran in CI: the bindx-form, bindx-uploader and bindx-generator
package suites plus tests/bindx-client and tests/repeater. The has-many
materialisation bug fixed in #76 sat failing in
packages/bindx-form/tests the whole time, behind a green board.

Use an ignore pattern instead of an allow-list, so a new test directory
is covered by default and cannot silently drop out again. Drop test:all,
which now differs only by also running tests/browser and fails without a
live playground.

Gate: 1531 tests across 129 files -> 1737 across 149, 0 fail.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant