I am trying to access a child view of a view. This is the line I am currently trying to get to work.
onData(withDesc("Description")).onChildView(withId(R.id.positive)).perform(click());
private static Matcher<Object> withDesc(String desc) {
return onView(withContentDescription(desc));
}
But this is returning a ViewInteraction
and not a Object
. How do I switch this so it will work?