Невозможно нажать на кнопку удаления, появляется сообщение об ошибке:
android.support.test.espresso.AmbiguousViewMatcherException: '(with id: cit:id/delete_button and has parent matching: with id: cit:id/count_and_delete and is displayed on the screen to the user)' matches multiple views in the hierarchy.
Я использую следующий код для нажатия на значок удаления:
ViewInteraction appCompatImageView222 = onView(
allOf(withId(R.id.delete_button),
withParent(withId(R.id.count_and_delete)),
isDisplayed()));
appCompatImageView222.perform(actionOnItemAtPosition(0, click()));
ViewInteraction appCompatImageView222 = onView(
allOf(withId(R.id.delete_button),
withParent(withId(R.id.count_and_delete)),
isDisplayed()));
appCompatImageView222.perform(click());