}
// SONAR-4739
@Test
public void shouldNotFailWhenUnableToDeserialize() throws Exception {
NotificationQueueDto dto1 = mock(NotificationQueueDto.class);
when(dto1.toNotification()).thenThrow(new InvalidClassException("Pouet"));
List<NotificationQueueDto> dtos = Arrays.asList(dto1);
when(notificationQueueDao.findOldest(1)).thenReturn(dtos);
manager = spy(manager);
assertThat(manager.getFromQueue()).isNull();