Skip to content

Commit 479dee4

Browse files
committed
docs(test/e2e): scrub stale useFixture references
Update the createGetFixture JSDoc and .claude/rules/e2e.md to reflect the createGetFixture rename and add runFileExistsTest to the helper list so future readers see the actual API.
1 parent 93ecfd5 commit 479dee4

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

.claude/rules/e2e.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ In CI, use `bunx playwright install chromium --with-deps` to include system-leve
131131

132132
Fixture files run in parallel (concurrency controlled by the runner, defaults to CPU count). Each fixture uses an isolated temp directory and `CLERK_CONFIG_DIR`, so there is no shared mutable state. Do not use `test.concurrent` within individual fixture files.
133133

134-
Within each test file, `useFixture()` runs `setupFixture()` once in `beforeAll` and shares the result with both the build test and browser test. This avoids duplicating the expensive setup.
134+
Within each test file, `createGetFixture()` runs `setupFixture()` once in `beforeAll` and shares the result with both the build test and browser test. This avoids duplicating the expensive setup.
135135

136136
## Adding a new fixture
137137

@@ -143,7 +143,7 @@ Within each test file, `useFixture()` runs `setupFixture()` once in `beforeAll`
143143
Helper functions are in `test/e2e/lib/`:
144144

145145
- `fixture-setup.ts` - `setupFixture`
146-
- `fixture-test.ts` - `useFixture`, `runFixtureTest`, `runBrowserTest`
146+
- `fixture-test.ts` - `createGetFixture`, `runFixtureTest`, `runFileExistsTest`, `runBrowserTest`
147147
- `dev-server.ts` - `startDevServer` (allocates a port internally and retries on collision), `killDevServer`, `buildDevCommand`
148148
- `test-user.ts` - `createTestUser`, `deleteTestUser`
149149
- `logger.ts` - `log`, `debug` (shared logging; set `CLERK_E2E_DEBUG=1` for verbose output)

test/e2e/lib/fixture-test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ export function createGetFixture(fixtureDir: string, config: FixtureConfig): Get
156156

157157
/**
158158
* Register a bun test that verifies the framework build command and
159-
* `tsc --noEmit` both pass using the shared fixture from `useFixture()`.
159+
* `tsc --noEmit` both pass using the shared fixture from `createGetFixture()`.
160160
*
161161
* Build runs first so frameworks that generate types during build
162162
* (TanStack Router routeTree.gen) have them available for tsc.

0 commit comments

Comments
 (0)