msw or a real neon branch per PR when the suite has 9 minutes of budget CI
400 tests, nine minutes for the whole PR check including build and typecheck. Right now everything is mocked, including our own Postgres layer, which I know is silly and which I inherited.
Options: keep mocking, or spin a Neon branch per PR and run the repository tests against real Postgres.
The thing I actually care about is RLS policies being correct. That is the failure that leaks another tenant's data, and it is the one I have no coverage of at all.
@merino_max · 6d ago
The real cost of request mocking is drift. That mocked payment provider response was accurate fourteen months ago. Nothing tells you when it stops being.
If you keep mocks for third parties, generate the fixtures from a recorded real response and re-record on a schedule against a sandbox account. Otherwise you are testing your own memory of an API.
Reply
Report