@Test
public void testDeployScriptsReportsErrorOnUploadError() throws Exception {

    when(fossologyUploader.copyToFossology(anyString(), any(InputStream.class), anyBoolean())).thenReturn(true, false);
    assertThat(fossologyScriptsHandler.deployScripts(), is(RequestStatus.FAILURE));
    verify(fossologyUploader, times(5)).copyToFossology(anyString(), any(InputStream.class), anyBoolean());
}