@Test
public void testRetrievingAnnotatedImageWhenTriggerStatusIsCleared() {

    Double triggerThreshold = 1D;
    Long triggerFiredTime = 1563692460000L;
    Long inertia = 1800*1000L;
    ImageDataRetrievalContext context = getImageDataRetrievalContext(Trigger.TriggerType.GREATER_THAN, triggerFiredTime, inertia, triggerThreshold, NotificationStatus.CLEARED);
    ArgumentMatcher<ImageProperties> imageProperties = new ArgumentMatcher<ImageProperties>() {
        @Override
        public boolean matches(ImageProperties imageProperties) {
            return imageProperties.getShadeYAxisArea() == null && imageProperties.getShadeXAxisArea() == null;
        }
    };
    when(imageServiceMock.generateAndStoreImage(eq(ImmutableList.of(context.getTriggeredMetric())), argThat(imageProperties),
            eq(true))).thenReturn(Pair.of("1", "TestString".getBytes()));
    Pair<String, byte[]> imageDetails = imageDataRetriever.getAnnotatedImage(context);
    verify(imageServiceMock, times(1)).generateAndStoreImage(
            eq(ImmutableList.of(context.getTriggeredMetric())), argThat(imageProperties), eq(true));
}