I\'m using the new TextInputLayout provided by Android.support to do floating label. But it will fail Espresso Accessibility Check because \"View is missing speakable text n
A great way to make TextInputLayout accessible is to use "LabelFor" as recommanded by ChrisCM, but you don't have to add an invisible label view to do so: Just put the labelFor
or your Textinputlayout
and make it point to your EditText
Example:
This way you get the exact same visual behaviour and make "Espresso Accessibility Check" and Talkback happy :)
(To make TextInputLayout fully accessible I also added android:accessibilityliveregion
on the TextInputLayout element to trigger talkback whenever the error is poping)
A big thanks to this post this blog post which helped a lot