Home > Net >  How to bring app to foreground in flutter integration test
How to bring app to foreground in flutter integration test

Time:02-10

I have an integration test which taps a text of phone number, then it opens the phone dial app which makes my app put to background.

final firstNumber = find.byWidgetPredicate(
      (widget) => widget is RichText && tapTextSpan(widget, '09123456789'));
await tester.tap(firstNumber);

After tester.tap() it successfully open the built in dial app in phone. How can I bring my app to foreground?

Package used: integration_test, flutter_test

CodePudding user response:

  •  Tags:  
  • Related