Skip to content
Docs
Changelog

End-to-end tests on one local stack that a killed run never leaves behind

apps/e2e runs web and iOS end-to-end tests with e2e on the built Worker and a locked temporary PostgreSQL; test-local-postgres and the RLS matrix sweep what a killed run left.

Markdown

  • Web and iOS end-to-end tests. pnpm test:e2e builds the Worker and runs the web suite in apps/e2e with e2e 0.23.1: sign up, verify, sign in; the seeded Member's session; create and delete a todo; /docs; the anonymous dashboard redirect; and the todo flow driven by agent goals, which skips without a model and replays from apps/e2e/recordings/ once recorded. pnpm test:e2e:mobile signs the seeded Member in on the Expo development build and finds a seeded todo. Locators come from the apps' own English catalogs. (End-to-end tests, f5b4ef72, 993c4f49)
  • One stack per machine, and nothing left behind. The suites' app command starts the built Worker in local workerd on a temporary PostgreSQL under a lock: a second run fails at once naming the owner pid, a dead owner's lock is taken over and its cluster and workerd stopped, a killed runner's stack stops itself, and the mobile wrapper shuts down only a simulator it booted. node scripts/e2e-cleanup-proof.mjs proves a normal run, kill -9 mid-run and two runs at once. (End-to-end tests, f5b4ef72)
  • Killed test runs no longer leave servers or containers. scripts/test-local-postgres.mjs --serve records its dev server group, and the next run stops it with the orphaned cluster; a SIGKILLed run used to leave wrangler/workerd serving. test:rls-matrix starts its containers with --rm, cleans up on SIGTERM and SIGHUP, and first removes, with their volumes, the containers of runs that are gone. (Testing, 6616cf79, 3d1f95cf)
  • CI. A new e2e workflow runs the web suite on same-repository pull requests and pushes to main with the runner's own PostgreSQL binaries and uploads apps/e2e/.e2e/; it holds no deploy or database secret. (End-to-end tests, 475c4251)
Edit on GitHubDocumentation is in English.
Cookie settings
We use essential cookies to make our app work. With your consent, we also use optional cookies to improve your experience.

Read our Cookie Policy and Privacy Policy.