@Test
public void testFetchServiceException() throws Exception {

  when(mockS3.getObject(any(GetObjectRequest.class)))
      .thenThrow(new AmazonServiceException("error"));
  try {
    downloader.fetch(record);
    failBecauseExceptionWasNotThrown(AmazonServiceException.class);
  } catch (AmazonServiceException e) {
  }
  verify(mockS3).getObject(any(GetObjectRequest.class));
}