一键导入
e2e
Playwright E2E testing patterns. Use when working on files in tests/e2e/.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Playwright E2E testing patterns. Use when working on files in tests/e2e/.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
UI component patterns for React 19, shadcn/ui, and Tailwind. Use when working on files in src/components/.
Loro CRDT state management with loro-mirror. Use when working on files in src/lib/crdt/.
CSV and OFX transaction import parsing. Use when working on files in src/lib/import/.
Real-time sync with Supabase, Loro CRDT, and IndexedDB. Use when working on files in src/lib/sync/.
tRPC v11 API layer with Zod and Ed25519 auth. Use when working on files in src/server/.
Client-side cryptography with libsodium. Use when working on files in src/lib/crypto/.
| name | e2e |
| description | Playwright E2E testing patterns. Use when working on files in tests/e2e/. |
test.step() to existing tests over creating new tests - keeps suite
fast and avoids duplicating slow setup flowspnpm playwright test --reporter=line --max-failures=1 2>&1
pnpm playwright test --workers=4 --repeat-each=5 --reporter=line 2>&1 # flaky detection
NEVER use --debug or --ui - opens GUI, blocks forever. This is a common mistake.
getByRole()getByTestId()getByLabel()getByText(/regex/i)beforeEach, don't depend on prior test statetoBeEnabled(), not waitForTimeout()Import from tests/e2e/helpers/:
createNewIdentity(page) - full new user flowgoToTransactions(page), goToTags(page), etc.Create helpers for multi-step reused flows. Don't wrap single Playwright calls.
test.describe("Feature", () => {
test.beforeEach(async ({ page }) => {
await createNewIdentity(page);
await goToFeature(page);
});
test("should do thing", async ({ page }) => {
// Arrange → Act → Assert
});
});