MCPcopy Create free account
hub / github.com/callstack/react-native-testing-library / press

Function press

src/user-event/press/press.ts:26–34  ·  view source on GitHub ↗
(this: UserEventInstance, instance: TestInstance)

Source from the content-addressed store, hash-verified

24}
25
26export async function press(this: UserEventInstance, instance: TestInstance): Promise<void> {
27 if (!isTestInstance(instance)) {
28 throw new ErrorWithStack(`press() works only with host instances.`, press);
29 }
30
31 await basePress(this.config, instance, {
32 type: 'press',
33 });
34}
35
36export async function longPress(
37 this: UserEventInstance,

Callers

nothing calls this directly

Calls 2

isTestInstanceFunction · 0.90
basePressFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…