@Test(expected = RuntimeException.class)
public void testGetLastUpdated_fail() {

    val timeInSecs = 60;
    when(detectorMappingRepo.findLastUpdated(timeInSecs)).thenThrow(new IOException());
    List<DetectorMapping> detectorMappings = controllerUnderTest.findDetectorMapping(timeInSecs);
    assertNotNull("Response can't be null", detectorMappings);
    assertEquals(0, detectorMappings.size());
}