File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed
example/tests/src/android/androidTest Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change 33import static androidx .test .espresso .Espresso .onView ;
44import static androidx .test .espresso .action .ViewActions .click ;
55import static androidx .test .espresso .action .ViewActions .replaceText ;
6+ import static androidx .test .espresso .matcher .ViewMatchers .withParent ;
67import static androidx .test .espresso .matcher .ViewMatchers .withResourceName ;
78import static androidx .test .espresso .matcher .ViewMatchers .withText ;
89
10+ import static org .hamcrest .Matchers .allOf ;
11+
912import androidx .test .ext .junit .rules .ActivityScenarioRule ;
1013import androidx .test .ext .junit .runners .AndroidJUnit4 ;
1114
@@ -23,10 +26,17 @@ public class InvokeInstabugUITest {
2326 @ Test
2427 public void ensureInstabugInvocation () throws InterruptedException {
2528 Thread .sleep (5000 );
26- onView (withResourceName ("instabug_floating_button" )).perform (click ());
2729
30+ onView (withResourceName ("instabug_floating_button" )).perform (click ());
2831 onView (withText ("Report a bug" )).perform (click ());
29- onView (withResourceName ("instabug_edit_text_email" )).perform (replaceText ("inst@bug.com" ));
32+
33+ onView (
34+ allOf (
35+ withResourceName ("ib_edit_text" ),
36+ withParent (withResourceName ("instabug_edit_text_email" ))
37+ )
38+ ).perform (replaceText ("inst@bug.com" ));
39+
3040 onView (withResourceName ("instabug_bugreporting_send" )).perform (click ());
3141 onView (withResourceName ("instabug_success_dialog_container" )).perform (click ());
3242 }
You can’t perform that action at this time.
0 commit comments