firebase / FirebaseUI-Android

Optimized UI components for Firebase
https://firebaseopensource.com/projects/firebase/firebaseui-android/
Apache License 2.0
4.63k stars 1.84k forks source link

Add IdlingResources for succesfull Espresso testing #1137

Open peterhav opened 6 years ago

peterhav commented 6 years ago

Step 3: Describe the problem:

Steps to reproduce:

  1. Create a testcase which involes the creation of a new user mail account using Firebase-UI
  2. In the test case code, after supplying the mail adress, click next
  3. The test will fail since it cannot find the password field

Observed Results:

Expected Results:

Espresso test cases covering Firebase UI code can run without adding waits in the test code.

samtstern commented 6 years ago

@peterhav thanks for the idea, it would be good if the whole UI was more espresso-testable. Once we finish our current refactor (which will add a much better unit testing layer) we can probably look at this.

francos commented 6 years ago

Hi @samtstern, any idea of when the current refactor you described in your comment above will be available?

SUPERCILEX commented 6 years ago

The big refactor will be complete in v4.1, but we haven't made any progress regarding Espresso. Sorry! 😊

zjamshidi commented 2 years ago

I'm facing the same issue. I wanted to write some simple login tests but got stuck here. I could check the visibility of top_progress_bar to find the password field (I know it's a bad workaround). However, since there is no IdlingResource I couldn't check if the login has finished or not.

It's been more than 4 years. Would you please help us with this issue?