Пример #1
0
 @Test
 public void shouldReportThatPublicationHasBeenConnectedYet() {
   when(conductor.isPublicationConnected(anyLong())).thenReturn(true);
   assertTrue(publication.isConnected());
 }
Пример #2
0
 @Test
 public void shouldReportThatPublicationHasNotBeenConnectedYet() {
   when(publicationLimit.getVolatile()).thenReturn(0L);
   when(conductor.isPublicationConnected(anyLong())).thenReturn(false);
   assertFalse(publication.isConnected());
 }