Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #26 : Resolve Apache RAT via the buildscript context #27

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/main/kotlin/org/nosphere/apache/rat/RatTask.kt
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ open class RatTask private constructor(
@get:Classpath
internal
val ratClasspath: FileCollection = objects.fileCollection().apply {
from(project.run {
from(project.buildscript.run {
configurations.detachedConfiguration(
dependencies.create("org.apache.rat:apache-rat:$ratVersion")
)
Expand Down
6 changes: 0 additions & 6 deletions src/test/kotlin/org/nosphere/apache/rat/BaseRatPluginTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,6 @@ class BaseRatPluginTest(testMatrix: TestMatrix) : AbstractPluginTest(testMatrix)
plugins {
id("org.nosphere.apache.rat-base")
}
repositories {
mavenCentral()
}
task("assertion") {
def hasRat = project.tasks.findByName('rat') != null
doLast {
Expand All @@ -56,9 +53,6 @@ class BaseRatPluginTest(testMatrix: TestMatrix) : AbstractPluginTest(testMatrix)
plugins {
id("org.nosphere.apache.rat-base")
}
repositories {
mavenCentral()
}
task someRat(type: org.nosphere.apache.rat.RatTask) {
verbose.set(true)
inputDir.set(rootDir)
Expand Down
21 changes: 0 additions & 21 deletions src/test/kotlin/org/nosphere/apache/rat/RatPluginTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,6 @@ class RatPluginTest(testMatrix: TestMatrix) : AbstractPluginTest(testMatrix) {
id("base")
id("org.nosphere.apache.rat")
}
repositories {
mavenCentral()
}
tasks.rat {
verbose.set(true)
excludes = [
Expand Down Expand Up @@ -88,9 +85,6 @@ class RatPluginTest(testMatrix: TestMatrix) : AbstractPluginTest(testMatrix) {
id("base")
id("org.nosphere.apache.rat")
}
repositories {
mavenCentral()
}
tasks.rat {
verbose.set(true)
excludes = [
Expand Down Expand Up @@ -120,9 +114,6 @@ class RatPluginTest(testMatrix: TestMatrix) : AbstractPluginTest(testMatrix) {
id("base")
id("org.nosphere.apache.rat")
}
repositories {
mavenCentral()
}
tasks.rat {
verbose.set(true)
failOnError.set(false)
Expand Down Expand Up @@ -154,9 +145,6 @@ class RatPluginTest(testMatrix: TestMatrix) : AbstractPluginTest(testMatrix) {
id("base")
id("org.nosphere.apache.rat")
}
repositories {
mavenCentral()
}
tasks.rat {
verbose.set(true)
excludes = ['build.gradle', 'settings.gradle', 'build/**', '.gradle/**', '.gradle-test-kit/**']
Expand All @@ -183,9 +171,6 @@ class RatPluginTest(testMatrix: TestMatrix) : AbstractPluginTest(testMatrix) {
id("base")
id("org.nosphere.apache.rat")
}
repositories {
mavenCentral()
}
tasks.rat {
verbose.set(true)
addDefaultMatchers.set(false)
Expand All @@ -209,9 +194,6 @@ class RatPluginTest(testMatrix: TestMatrix) : AbstractPluginTest(testMatrix) {
id("base")
id("org.nosphere.apache.rat")
}
repositories {
mavenCentral()
}
tasks.rat {
verbose.set(true)
approvedLicenses.add("MIT")
Expand Down Expand Up @@ -254,9 +236,6 @@ class RatPluginTest(testMatrix: TestMatrix) : AbstractPluginTest(testMatrix) {
id("base")
id("org.nosphere.apache.rat")
}
repositories {
mavenCentral()
}
$someTask
tasks.rat {
verbose.set(true)
Expand Down