@Test
public void testUpdaterArtifactToReleaseUploadDisabled() throws IOException {

    Path sourceFile = createTestFile();
    Artifact artifact = TestUtils.mkArtifact("test", false);
    artifact.addFact(new ArtifactSourceFile(sourceFile));
    SW360Release release = createRelease("test", sourceFile);
    SW360Release createdRelease = createRelease("testCreated", sourceFile);
    when(metaDataUpdater.getOrCreateRelease(release, true))
            .thenReturn(createdRelease);
    SW360UpdaterImpl updater = new SW360UpdaterImpl(metaDataUpdater, "test", "version",
            true, false, false);
    AttachmentUploadResult<SW360Release> result =
            updater.artifactToReleaseWithUploads(artifact, release, Collections.emptyMap());
    assertThat(result.getTarget()).isEqualTo(createdRelease);
    verify(metaDataUpdater, never()).uploadAttachments(any(), any(), anyBoolean());
}