MCPcopy Create free account
hub / github.com/boringstack-xyz/boringstack / baseMe

Function baseMe

apps/ui/src/app/router/ProtectedRoute.test.tsx:43–52  ·  view source on GitHub ↗
(
  overrides: Record<string, unknown>
)

Source from the content-addressed store, hash-verified

41 * The mock returns a partial UseQueryResult: only the fields
42 * ProtectedRoute reads. Every test case has to include `error`,
43 * `isFetching`, and `refetch` so the destructure in the component
44 * doesn't see `undefined` and confuse `resolveAuthStatus`.
45 */
46const baseMe = (
47 overrides: Record<string, unknown>
48): Record<string, unknown> => ({
49 data: undefined,
50 error: null,
51 isPending: false,
52 isFetching: false,
53 refetch: vi.fn(),
54 ...overrides
55});

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected