diff options
Diffstat (limited to 'juick-notifications/src/test')
-rw-r--r-- | juick-notifications/src/test/java/com/juick/components/test/NotificationTests.java | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/juick-notifications/src/test/java/com/juick/components/test/NotificationTests.java b/juick-notifications/src/test/java/com/juick/components/test/NotificationTests.java index f1a4787d..573771fc 100644 --- a/juick-notifications/src/test/java/com/juick/components/test/NotificationTests.java +++ b/juick-notifications/src/test/java/com/juick/components/test/NotificationTests.java @@ -21,12 +21,9 @@ import ch.qos.logback.classic.Level; import ch.qos.logback.classic.Logger; import ch.qos.logback.classic.spi.LoggingEvent; import ch.qos.logback.core.Appender; -import com.juick.components.CleanUp; import com.juick.components.Notifications; -import com.juick.components.service.TokenService; import org.junit.Before; import org.junit.Test; -import org.mockito.InjectMocks; import org.mockito.Mock; import org.mockito.MockitoAnnotations; import org.slf4j.LoggerFactory; @@ -41,14 +38,10 @@ import static org.mockito.Mockito.*; * Created by vitalyster on 22.11.2016. */ public class NotificationTests { - @InjectMocks - CleanUp cleanUp; @Mock RestTemplate rest; @Mock - TokenService tokenService; - @Mock Notifications push; @@ -66,7 +59,7 @@ public class NotificationTests { when(mockAppender.getName()).thenReturn("MOCK"); root.setLevel(Level.DEBUG); root.addAppender(mockAppender); - cleanUp.cleanupTokens(); + push.cleanupTokens(); verify(mockAppender).doAppend(argThat(argument -> ((LoggingEvent)argument).getFormattedMessage().contains("1 tokens"))); } |