ensureVisible method

Future<void> ensureVisible(
  1. dynamic target, {
  2. Screenshot? screenshot,
})

Implementation

Future<void> ensureVisible(dynamic target, {Screenshot? screenshot}) async {
  var finder = targetToFinder(target, skipOffStage: false);
  await tester.ensureVisible(finder);
  await pumpAndSettle();
  await _screenshotIfNeeded(screenshot);
}