원클릭으로
e2e-test
Generate Playwright E2E tests following project conventions (Tauri fixture, storage isolation, helpers).
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Generate Playwright E2E tests following project conventions (Tauri fixture, storage isolation, helpers).
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Drive the real GUI against the real engine via the standalone dev HTTP bridge (`npm run dev:bridge`). Use whenever "does the wiring test actually hold up against real code?" matters — smoke verification, UI development with live engine state, real-engine bug repro, exploratory debugging with Chrome DevTools instruments.
Generate unit tests following project conventions. Use when the user asks to create, generate, or write tests for a file or component.
Scaffold a new React component with co-located test, shadcn/ui primitives, and barrel export registration.
Review changes and determine if PROJECT_SHADOW.md needs updating per AI_CONTRACT.md criteria. Runs automatically during code review.
Scaffold a new Tauri command across Rust backend and TypeScript frontend with proper patterns.
| name | e2e-test |
| description | Generate Playwright E2E tests following project conventions (Tauri fixture, storage isolation, helpers). |
Generate Playwright E2E tests for the specified feature or user flow.
Input: Feature or flow to test. Example: /e2e-test profile selection persistence across reload
Steps
e2e/<descriptive-name>.spec.tsnpx playwright test e2e/<spec-file> --list (lists tests without running)Project Conventions
@playwright/test directly:
import { test, expect } from './fixtures/tauri';
__TAURI__ mock and __ENDSTATE_MOCK_ENGINE__ into the browser contexte2e/helpers/ui-mode.ts:
forceAdvancedMode(page) — enable sidebar navigation (call in addInitScript before goto)forceDefaultMode(page) — Overview-centric modegoToApplyPage(page) — navigate to and expand Apply cardgoToCapturePage(page) — navigate to and expand Capture cardgoToVerifyPage(page) — navigate to and expand Verify cardseedProfileSettings(page) — seed profile via addInitScript before gotoseedProfilesViaHook(page) — seed profiles after page loads via E2E hookVITE_STORAGE_NS=test prefixes all localStorage keys with test:test.use({ tauriMockOptions: { invoke: { ... } } })Mock Pattern for Tauri Commands
test.use({
tauriMockOptions: {
invoke: {
list_manifest_files: () => [
{ name: 'my-profile', path: 'C:\\profiles\\my-profile.jsonc', displayName: 'My Profile' }
],
check_file_exists: () => true,
}
}
});
Spec Template
import { test, expect } from './fixtures/tauri';
import { forceDefaultMode, goToApplyPage } from './helpers/ui-mode';
test.describe('Feature Name', () => {
test.use({
tauriMockOptions: {
invoke: {
list_manifest_files: () => [],
}
}
});
test.beforeEach(async ({ page }) => {
await page.goto('/');
await page.waitForLoadState('networkidle');
});
test('describes expected behavior', async ({ page }) => {
// Arrange: set up state
// Act: user interactions
// Assert: verify outcomes
await expect(page.getByRole('heading', { name: /expected/i })).toBeVisible();
});
});
Known Pitfalls
page.dispatchEvent() workaround or evaluate-based selection.waitForLoadState('networkidle') after goto('/') before interacting{ timeout: 5000 } on assertions that depend on async renderinggetByRole and getByText locators. Use data-testid locators only for structural elements (cards, panels)