@@ -249,7 +249,7 @@ public void testBackground() {
249
249
// direct child of RecyclerView which is expected to have the background set
250
250
// on it. If the internal implementation of NavigationView changes, the second
251
251
// Matcher below will need to be tweaked.
252
- Matcher menuItemMatcher =
252
+ Matcher < View > menuItemMatcher =
253
253
allOf (
254
254
hasDescendant (withText (menuStringContent .get (MENU_CONTENT_ITEM_IDS [i ]))),
255
255
isChildOfA (isAssignableFrom (RecyclerView .class )),
@@ -265,7 +265,7 @@ public void testBackground() {
265
265
// And check that all the menu items have the new fill
266
266
final @ ColorInt int newFillColorBlue = ResourcesCompat .getColor (res , R .color .test_blue , null );
267
267
for (int i = 0 ; i < MENU_CONTENT_ITEM_IDS .length ; i ++) {
268
- Matcher menuItemMatcher =
268
+ Matcher < View > menuItemMatcher =
269
269
allOf (
270
270
hasDescendant (withText (menuStringContent .get (MENU_CONTENT_ITEM_IDS [i ]))),
271
271
isChildOfA (isAssignableFrom (RecyclerView .class )),
@@ -283,7 +283,7 @@ public void testBackground() {
283
283
// And check that all the menu items have the new fill
284
284
final @ ColorInt int newFillColorGreen = ResourcesCompat .getColor (res , R .color .test_green , null );
285
285
for (int i = 0 ; i < MENU_CONTENT_ITEM_IDS .length ; i ++) {
286
- Matcher menuItemMatcher =
286
+ Matcher < View > menuItemMatcher =
287
287
allOf (
288
288
hasDescendant (withText (menuStringContent .get (MENU_CONTENT_ITEM_IDS [i ]))),
289
289
isChildOfA (isAssignableFrom (RecyclerView .class )),
@@ -575,15 +575,15 @@ private void verifyCheckedAppearance(
575
575
576
576
// For the background fill check we need to select a view that has its background
577
577
// set by the current implementation (see disclaimer in testBackground)
578
- Matcher menuItemMatcher =
578
+ Matcher < View > menuItemMatcher =
579
579
allOf (
580
580
hasDescendant (withText (menuStringContent .get (MENU_CONTENT_ITEM_IDS [i ]))),
581
581
isChildOfA (isAssignableFrom (RecyclerView .class )),
582
582
isDescendantOfA (withId (R .id .start_drawer )));
583
583
onView (menuItemMatcher ).check (matches (withBackgroundFill (expectedItemBackground )));
584
584
585
585
// And for the foreground color check we need to select a view with the text content
586
- Matcher menuItemTextMatcher =
586
+ Matcher < View > menuItemTextMatcher =
587
587
allOf (
588
588
withText (menuStringContent .get (MENU_CONTENT_ITEM_IDS [i ])),
589
589
isDescendantOfA (withId (R .id .start_drawer )));
@@ -684,7 +684,7 @@ public void testActionLayout() {
684
684
// details of the NavigationMenu, while conditions 3 and 4 aim to be as generic as
685
685
// possible and to not rely on the internal details of the current layout implementation
686
686
// of an individual menu item in NavigationMenu.
687
- Matcher menuItemMatcher =
687
+ Matcher < View > menuItemMatcher =
688
688
allOf (
689
689
isDescendantOfA (withId (R .id .start_drawer )),
690
690
isChildOfA (isAssignableFrom (RecyclerView .class )),
@@ -698,7 +698,7 @@ public void testActionLayout() {
698
698
699
699
// Check that the full custom view is displayed without title and icon.
700
700
final Resources res = activityTestRule .getActivity ().getResources ();
701
- Matcher customItemMatcher =
701
+ Matcher < View > customItemMatcher =
702
702
allOf (
703
703
isDescendantOfA (withId (R .id .start_drawer )),
704
704
isChildOfA (isAssignableFrom (RecyclerView .class )),
0 commit comments