Closed Nikitae57 closed 1 year ago
androidx.test.espresso.matcher.ViewMatchers.WithCharSequenceMatcher#matchesSafely caches text
@Override protected boolean matchesSafely(TextView textView, Description mismatchDescription) { if (null == expectedText) { try { expectedText = textView.getResources().getString(resourceId); } catch (Resources.NotFoundException ignored) { /* view could be from a context unaware of the resource id. */ } resourceName = safeGetResourceEntryName(textView.getResources(), resourceId); } ... }
I'll create a PR shortly
Steps to reproduce:
Observed Results:
Expected Results:
Relevant Code:
androidx.test.espresso.matcher.ViewMatchers.WithCharSequenceMatcher#matchesSafely caches text