vendredi 17 juillet 2020

How to check clickable checkbox with Espresso?

I have clickable checkbox in my application, it looks like this:

Img

If user taps on "Termns and Conditions" then web browser will be opened.

I am writing Espresso test and onView(withId(R.id.myCheckbox)).perform(click()) actually opens web browser instead of checking checkbox - as I would click "Terms and Conditions" . Is there any possibility to check that checkbox with Espresso without modyfing my code? This checkbox must remain clickable.

Aucun commentaire:

Enregistrer un commentaire