add-e2e-test

Installation
SKILL.md

add-e2e-test

The e2e tier exists to run the built dist/cli.mjs against a real Metabase, with no mocks. Subtle violations of the harness contract corrupt shared state for every other test in the run. Reading this is required before generating any e2e file.

Step 0 — Pre-flight (mandatory, do not skip)

Before generating anything, anchor to the existing harness:

  1. ls tests/e2e/ — see the layout and existing nouns.
  2. Read one existing e2e test end-to-end (e.g. tests/e2e/auth.e2e.test.ts).
  3. Read tests/e2e/run-cli.ts (helpers) and tests/e2e/bootstrap-data.ts (the Bootstrap schema you must NOT redeclare).

Skip this and you will reinvent harness pieces that already exist, or redeclare the bootstrap schema and silently drift from the writer.

When to add an e2e test

  • A new command was added under src/commands/<noun>/<verb>.ts. Every new command needs an e2e test.
  • An existing command grew a flag, output mode, or behavior that unit tests cannot exercise (real network round-trip, real auth flow, real polling).
Installs
2
Repository
metabase/mb-cli
GitHub Stars
3
First Seen
Jun 19, 2026
add-e2e-test — metabase/mb-cli