How could I check the font size, height, and width of an EditText with Espresso?
At the moment to sect the text I use:
onView(withId(R.id.editText1)).perform(clearText(), typeText("Amr"));
And to read the text:
onView(withId(R.id.editText1)).check(matches(withText("Amr")));
You will have to create your own custom matchers since Espresso does not support any of these matchers by default.
Luckily this can be done quite easily. Take a look at this example for font size:
}
Then create an entrypoint like so:
And use it like this:
For width & height it can be done in a similar manner.
Matcher for view size
using