You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Mockito-Collections is primarily aimed at injecting Collections of Mocks into an Object that is under test. We could potentially consider reversing this as well, for example given the annotation InjectOutOf:
@InjectMocks
private MyDelegate delegate;
@InjectOutOf
private Collection<MyListener> listeners;
@Test
public void shouldAdd() {
// Given
MyListener listener = mock(MyListener.class);
// When
delegate.add(listener);
// Then
// assertTrue(listeners.contains(listener));
}
The text was updated successfully, but these errors were encountered:
Mockito-Collections is primarily aimed at injecting Collections of Mocks into an Object that is under test. We could potentially consider reversing this as well, for example given the annotation InjectOutOf:
The text was updated successfully, but these errors were encountered: