MCPcopy
hub / github.com/getsentry/sentry-react-native / mockFunction

Function mockFunction

packages/core/test/testutils.ts:9–11  ·  view source on GitHub ↗
(fn: T)

Source from the content-addressed store, hash-verified

7} & T;
8
9export function mockFunction<T extends (...args: any[]) => any>(fn: T): jest.MockedFunction<T> {
10 return fn as jest.MockedFunction<T>;
11}
12
13export const firstArg = 0;
14export const secondArg = 1;

Callers 6

appStart.test.tsFile · 0.90
mockAppStartFunction · 0.90
mockTooLongAppStartFunction · 0.90
mockTooOldAppStartFunction · 0.90

Calls

no outgoing calls

Tested by 3

mockAppStartFunction · 0.72
mockTooLongAppStartFunction · 0.72
mockTooOldAppStartFunction · 0.72