requestData method

Future<String> requestData(
  1. String? message,
  2. {Duration? timeout}

Sends a string and returns a string.

This enables generic communication between the driver and the application. It's expected that the application has registered a DataHandler callback in enableFlutterDriverExtension that can successfully handle these requests.


Future<String> requestData(String? message, { Duration? timeout }) async {
  return RequestDataResult.fromJson(await sendCommand(RequestData(message, timeout: timeout))).message;