0

I have written an integration test for my flutter project where I have three screens, 1 where user input his email (i.e login screen) , second OTP verification screen, third is home screen, I wrote a test for login screen , found Textfield -> sent email as text inside it , found login Button -> tapped on that , moved to OTP screen , now I have to manually put OTP which is landed into my email, when I try to click on the textfield it doesn't let me paste / input from keyboard., whenever I click on any widget on that screen , it shows the location of that widget i.e complete hierarchy of the widget for example, Scaffold -> SingleChildScrollView -> Column -> Textfield something like that. but wont let me paste the OTP code or type it myself. How is this possible to give input by myself while test? is this even possible?

I tried to put a Future.delayed with few seconds to halt the process until i myself paste the OTP and press verify the button.

Alex Sunder Singh
  • 2,378
  • 1
  • 7
  • 17
Shafqat Nadeem
  • 184
  • 1
  • 1
  • 9

0 Answers0