Test what the component does, not how it does it.
Paste one Vue 3 component, composable or Pinia store. Your browser reads its public surface -
props, emits, store state, getters and actions - and picks the Pinia setup the unit-test-vue-pinia skill
recommends, for free. Write gives you a Vitest file with one test per behaviour, driven through
props, clicks and emitted events, with createTestingPinia set up the least powerful way that works.
Review checks the tests you already have: wrapper.vm, snapshots, unawaited triggers,
the clock, mock resets and missing coverage - and never flags the minimal Pinia setups that are fine.
The components and stores are invented. Each example comes with a saved model reply, so you can see the whole page without signing in or spending a credit.
What this does, and what it does not
Vue tests rot in two familiar ways: they test the implementation - reading wrapper.vm, snapshotting
markup that changes every sprint - or they drag a whole real store into every component test. The
unit-test-vue-pinia skill answers both: identify the behaviour boundary first, drive the test through public
inputs (props, user-like interactions, emitted events, store APIs), assert observable outputs, and set Pinia up with
the least powerful option that still covers the scenario. This page runs that method on one unit.
The free part runs in your browser: the unit's public surface read from defineProps,
defineEmits, defineModel, slots, defineStore state, getters and actions or a
composable's return values; the recommended Pinia strategy and mount; a lint of a pasted test file; and a spec
skeleton with one it.todo per behaviour. Write turns that into a complete Vitest file - shallow mount by
default, createTestingPinia({ createSpy: vi.fn }) when a component uses a store,
setActivePinia(createPinia()) for a pure store - and names what it leaves untested. Review reads your
file test by test, ranks the findings, lists the minimal setups that are correct as they are
(createTestingPinia({}), initialState or stubActions without
createSpy when no spy is inspected), and hands the missing coverage back to Write.
It does not run your tests: the page checks the shape of what it writes - one test per case, the declared setup, its own lint - not whether the file passes in your project. Derived from the agent skill @github/unit-test-vue-pinia (github.com/github/awesome-copilot, MIT). Sources are listed in llms.txt.