@Test
public void shouldReturnNullWhenObjectListingIsNull() {

    doReturn(null).when(mockClient).listObjects(any(ListObjectsRequest.class));
    S3ArtifactStore store = new S3ArtifactStore(mockClient, "foo-bar");
    String prefix = store.getLatestPrefix("pipeline", "stage", "job", "1");
    assertNull(prefix);
}