tap method
Taps on the native view specified by selector.
It waits for the view to become visible for timeout duration.
If the native view is not found, an exception is thrown.
appId is only used on iOS, where native queries must be scoped to a
single application. If not provided, defaults to the bundle id of the
app under test.
Implementation
Future<void> tap(
CompoundSelector selector, {
String? appId,
Duration? timeout,
}) {
return action.safe(
android: () => android.tap(selector.android, timeout: timeout),
ios: () => ios.tap(selector.ios, appId: appId, timeout: timeout),
web: () => web.tap(selector.web),
macos: _throwOnMacOS,
desktop: () => desktop.tap(
name: selector.android.text,
className: selector.android.className,
),
);
}