Skip to main content

Testing at KA26 — Overview

Single-page tour of every test layer in the KA26 codebase. Detail pages drill into philosophy, the suites, running, writing, live verification, and regression tracking.

Why this section exists

KA26 ships fast — we have committed to a "no regression, ever" rule (see BUGS-FIXED.md in the marketplace repo). Every feature we ship has bitten us at least once when we changed something else and forgot to test the affected flow. The test layers below exist so a single npm test catches >95% of those regressions before they reach a tester.

If you're adding a feature: read Test philosophy first to know what kind of test to write.

If you're debugging a flaky test: read Test suites to find which file owns the assertion.

If you're verifying a live fix: read Live verification for the JWT-against-prod pattern we use.

The 4 layers at a glance

LayerToolWhat it catchesSpeed
1. File-shape contractVitest (node)"Did someone delete this function call / i18n key / route?"~3s for 2600+ tests
2. Component integrationVitest (jsdom) + RTL"Does the bell click navigate to the right URL? Does the modal show?"~1s per test
3. Mobile componentJest + RNTL (3 separate suites)RN component mounts, callbacks fire, fake interactions work5-30s per app
4. Live verificationcurl + JWT + psql against prod"Does the API actually return the right shape on real data?"ad hoc / hourly cron

These are NOT replacements for each other — each layer catches a different bug class. See Philosophy for the full mapping.

Numbers as of 2026-05-01

SuiteTestsNotes
Marketplace root (npm test)2668 / 2668 passWeb + cross-app file-shape + Vitest jsdom integration
mobile/ (consumer Jest)422 pass / 9 pre-existing failsPre-existing fails are decommissioned /api/restaurants Eats tests — not from our work
mobile-seller/ (Jest)86 pass / 5 pre-existing failsSame pattern; failures are in earnings/home/orders integration tests, broken before this work
mobile-doctor/ (Jest)rarely runDoctor flow deprioritized
Live e2e smoke (hourly cron)42 production checks/api/health, e2e-smoke, e2e-signup-smoke, e2e-critical-funnels-smoke

When you ship something

The minimum bar (per BUGS-FIXED.md "no regression" rule):

  1. Add a layer-1 file-shape test for any function/string you depend on
  2. Add a layer-2 jsdom test if you added a new UI component with user input
  3. Run npm test from the marketplace root — must be green
  4. For backend changes, do a layer-4 live verification against prod after deploy
  5. Update this doc if you introduced a new test pattern

Next pages