I’m writing tests for application that is compiled and obfuscated. Currently to access View
I use Id form /res/values/public.xml
View myView = solo.getView(0x7f0b0030);
solo.clickOnView(((LinearLayout) (myView)).getChildAt(3));
This approach is valid only util application is not recompiled.
Is there any way to acces view by Id without having R file?
You can access ID of a resource by name using Resources class.
For example:
The same trick should work for layout as well.