( this: UserEventInstance, instance: TestInstance, options?: PressOptions, )
| 34 | } |
| 35 | |
| 36 | export async function longPress( |
| 37 | this: UserEventInstance, |
| 38 | instance: TestInstance, |
| 39 | options?: PressOptions, |
| 40 | ): Promise<void> { |
| 41 | if (!isTestInstance(instance)) { |
| 42 | throw new ErrorWithStack(`longPress() works only with host instances.`, longPress); |
| 43 | } |
| 44 | |
| 45 | await basePress(this.config, instance, { |
| 46 | type: 'longPress', |
| 47 | duration: options?.duration ?? DEFAULT_LONG_PRESS_DELAY_MS, |
| 48 | }); |
| 49 | } |
| 50 | |
| 51 | interface BasePressOptions { |
| 52 | type: 'press' | 'longPress'; |
nothing calls this directly
no test coverage detected
searching dependent graphs…