Skip to content

Commit f8903dd

Browse files
committed
docs: update testing principles to enhance test reliability
- Added a guideline for writing tests that can run offline, emphasizing the use of local fakes/fixtures instead of relying on the public internet and third-party services.
1 parent 009b8b5 commit f8903dd

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

docs/agents/testing-principles.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ magic.
1313
- Build helpers that return ready-to-run objects (factory pattern), not globals.
1414
- Keep test intent obvious in the name: "auth handler returns 400 for invalid
1515
JSON".
16+
- Write tests so they could run offline if necessary: avoid relying on the
17+
public internet and third-party services; prefer local fakes/fixtures.
1618
- Prefer fast unit tests for server logic; keep e2e tests focused on journeys.
1719
- Run server tests with `bun test server` to avoid Playwright spec discovery.
1820

0 commit comments

Comments
 (0)