-
Notifications
You must be signed in to change notification settings - Fork 118
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
improve when signing tasks run, consider all targets for signing (#30)
- signing configuration isn't part of afterEvaluate anymore which makes manually overriding it easier - required (= task fails when signing isn't set up on the local machine) only considers if the task is a snapshot - signing will only be run when also running an `Upload` task (not during things like assemble) - the previous point will now consider all targets, before only `uploadArchives` was considered - added info level logs to make debugging issues easier fixes #29
- Loading branch information
1 parent
4b908e6
commit 7bed96e
Showing
3 changed files
with
61 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
src/test/kotlin/com/vanniktech/maven/publish/MavenPublishTargetTest.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
package com.vanniktech.maven.publish | ||
|
||
import com.vanniktech.maven.publish.MavenPublishPluginExtension.Companion.DEFAULT_TARGET | ||
import com.vanniktech.maven.publish.MavenPublishPluginExtension.Companion.LOCAL_TARGET | ||
import org.assertj.core.api.Java6Assertions.assertThat | ||
import org.junit.Test | ||
|
||
class MavenPublishTargetTest { | ||
|
||
@Test | ||
fun uploadArchivesTaskName() { | ||
assertThat(MavenPublishTarget(DEFAULT_TARGET).taskName).isEqualTo("uploadArchives") | ||
} | ||
|
||
@Test | ||
fun installArchivesTaskName() { | ||
assertThat(MavenPublishTarget(LOCAL_TARGET).taskName).isEqualTo("installArchives") | ||
} | ||
|
||
@Test | ||
fun customTaskName() { | ||
assertThat(MavenPublishTarget("myRepo").taskName).isEqualTo("uploadArchivesMyRepo") | ||
} | ||
} |