- mockito-core 2.7.13 - OpenJDK 1.8.0_121 - Ubuntu 16.10 - Enable `mock-maker-inline` (or use `mockito-inline` artifact) If running the following test, 'Unnecessary Stubbing' is not detected. ```java @RunWith(MockitoJUnitRunner.StrictStubs.class) public class MockitoTest { @Mock ArrayList<String> mock; @Test public void should_pass() { when(mock.get(0)).thenReturn("foo"); assertEquals("foo", mock.get(0)); } @Test public void should_detect_unnecessary_stubbing() { when(mock.get(1)).thenReturn("foo"); } } ``` In the above code, 'Unnecessary Stubbing' is detected by changing ArrayList to List. ```java @Mock // ArrayList<String> mock; List<String> mock; ``` This problem does not occur with default mock maker.