MCPcopy
hub / github.com/callstack/react-native-testing-library / createConfig

Function createConfig

src/user-event/setup/setup.ts:77–90  ·  view source on GitHub ↗
(
  options: UserEventSetupOptions = {},
  // eslint-disable-next-line @typescript-eslint/no-unsafe-function-type
  callsite: Function,
)

Source from the content-addressed store, hash-verified

75}
76
77function createConfig(
78 options: UserEventSetupOptions = {},
79 // eslint-disable-next-line @typescript-eslint/no-unsafe-function-type
80 callsite: Function,
81): UserEventConfig {
82 const { delay, advanceTimers, ...rest } = options;
83 validateOptions('userEvent.setup', rest, callsite);
84
85 return {
86 ...defaultOptions,
87 ...(delay !== undefined && { delay }),
88 ...(advanceTimers !== undefined && { advanceTimers }),
89 };
90}
91
92/**
93 * UserEvent instance used to invoke user interaction functions.

Callers 1

setupFunction · 0.85

Calls 1

validateOptionsFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…