You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@groovy.apache.org by pa...@apache.org on 2022/03/20 10:57:53 UTC
[groovy] branch GROOVY_3_0_X updated: update gradle conventions
This is an automated email from the ASF dual-hosted git repository.
paulk pushed a commit to branch GROOVY_3_0_X
in repository https://gitbox.apache.org/repos/asf/groovy.git
The following commit(s) were added to refs/heads/GROOVY_3_0_X by this push:
new 1361caa update gradle conventions
1361caa is described below
commit 1361caade9bc126626b6c01d845cde12c6c8a8dc
Author: Paul King <pa...@asert.com.au>
AuthorDate: Sun Mar 20 20:57:46 2022 +1000
update gradle conventions
---
gradle/test.gradle | 6 ++----
subprojects/groovy-json/build.gradle | 6 +++---
subprojects/groovy-servlet/build.gradle | 6 ++----
subprojects/groovy-test-junit5/build.gradle | 4 ++--
subprojects/groovy-test/build.gradle | 6 +++---
subprojects/groovy-testng/build.gradle | 2 +-
subprojects/groovy-yaml/build.gradle | 4 ++--
7 files changed, 15 insertions(+), 19 deletions(-)
diff --git a/gradle/test.gradle b/gradle/test.gradle
index cd9d2b6..f53a78c 100644
--- a/gradle/test.gradle
+++ b/gradle/test.gradle
@@ -53,10 +53,8 @@ allprojects {
// create an Indy test suite
if (rootProject.indyCapable()) {
- def dependencies = configurations.testRuntime.incoming.dependencies.findAll {
- it.name.startsWith('groovy')
- }.collect {
- it.name
+ def dependencies = configurations.testRuntimeOnly.incoming.dependencies.findResults {
+ if (it.name.startsWith('groovy')) return it.name
}
task testWithIndy(type: Test) {
systemProperties 'groovy.target.indy': true
diff --git a/subprojects/groovy-json/build.gradle b/subprojects/groovy-json/build.gradle
index d9674ff..577bb07 100644
--- a/subprojects/groovy-json/build.gradle
+++ b/subprojects/groovy-json/build.gradle
@@ -21,9 +21,9 @@ dependencies {
testImplementation project(':groovy-test')
testImplementation project(':groovy-dateutil')
testImplementation 'net.javacrumbs.json-unit:json-unit:2.9.0'
- testRuntime 'com.google.code.gson:gson:2.8.7' // json-unit requires gson, jackson1, or jackson2
- testRuntime "org.slf4j:slf4j-api:$slf4jVersion"
- testRuntime project(':groovy-ant') // for JavadocAssertionTests
+ testRuntimeOnly 'com.google.code.gson:gson:2.8.7' // json-unit requires gson, jackson1, or jackson2
+ testRuntimeOnly "org.slf4j:slf4j-api:$slf4jVersion"
+ testRuntimeOnly project(':groovy-ant') // for JavadocAssertionTests
}
eclipse.classpath.file.whenMerged {
diff --git a/subprojects/groovy-servlet/build.gradle b/subprojects/groovy-servlet/build.gradle
index eb83925..224693f 100644
--- a/subprojects/groovy-servlet/build.gradle
+++ b/subprojects/groovy-servlet/build.gradle
@@ -26,10 +26,8 @@ dependencies {
}
api rootProject // ServletBinding extends Binding...
- // needed for MarkupBuilder
- implementation project(':groovy-xml')
- // needed by TemplateServlet
- implementation project(':groovy-templates')
+ implementation project(':groovy-xml') // needed for MarkupBuilder
+ implementation project(':groovy-templates') // needed by TemplateServlet
testImplementation "jmock:jmock:$jmockVersion"
testImplementation rootProject.sourceSets.test.runtimeClasspath
diff --git a/subprojects/groovy-test-junit5/build.gradle b/subprojects/groovy-test-junit5/build.gradle
index d998353..82b398a 100644
--- a/subprojects/groovy-test-junit5/build.gradle
+++ b/subprojects/groovy-test-junit5/build.gradle
@@ -30,8 +30,8 @@ dependencies {
exclude(group: 'org.apiguardian', module: 'apiguardian-api')
}
testImplementation "org.junit.jupiter:junit-jupiter-params:$junit5Version"
- testRuntime "org.junit.platform:junit-platform-engine:$junit5PlatformVersion"
- testRuntime "org.junit.platform:junit-platform-runner:$junit5PlatformVersion"
+ testRuntimeOnly "org.junit.platform:junit-platform-engine:$junit5PlatformVersion"
+ testRuntimeOnly "org.junit.platform:junit-platform-runner:$junit5PlatformVersion"
testImplementation project(':groovy-test')
}
diff --git a/subprojects/groovy-test/build.gradle b/subprojects/groovy-test/build.gradle
index 86c4768..4151e01 100644
--- a/subprojects/groovy-test/build.gradle
+++ b/subprojects/groovy-test/build.gradle
@@ -21,11 +21,11 @@ dependencies {
api rootProject // GroovyTestCase uses Closure...
api "junit:junit:$junitVersion" // GroovyTestCase extends TestCase...
// groovy-ant needed for FileNameFinder used in AllTestSuite and JavadocAssertionTestSuite
- testRuntime(project(':groovy-ant')) {
+ testRuntimeOnly(project(':groovy-ant')) {
transitive = false // bring in just what we need below
}
- testRuntime "org.apache.ant:ant:$antVersion"
- testRuntime "org.apache.ant:ant-launcher:$antVersion"
+ testRuntimeOnly "org.apache.ant:ant:$antVersion"
+ testRuntimeOnly "org.apache.ant:ant-launcher:$antVersion"
}
eclipse.classpath.file.whenMerged {
diff --git a/subprojects/groovy-testng/build.gradle b/subprojects/groovy-testng/build.gradle
index 3e5545e..f2f633f 100644
--- a/subprojects/groovy-testng/build.gradle
+++ b/subprojects/groovy-testng/build.gradle
@@ -18,7 +18,7 @@
*/
dependencies {
api rootProject // TestNgRunner implements GroovyRunner...
- runtime('org.testng:testng:7.5') {
+ implementation('org.testng:testng:7.5') {
exclude(group: 'com.google.inject', module: 'guice')
exclude(group: 'com.google.code.findbugs', module: 'jsr305')
exclude(group: 'junit', module: 'junit')
diff --git a/subprojects/groovy-yaml/build.gradle b/subprojects/groovy-yaml/build.gradle
index f413bf7..37125ec 100644
--- a/subprojects/groovy-yaml/build.gradle
+++ b/subprojects/groovy-yaml/build.gradle
@@ -27,8 +27,8 @@ dependencies {
implementation "com.fasterxml.jackson.core:jackson-databind:$jacksonVersion"
implementation project(':groovy-json')
testImplementation project(':groovy-test')
- testRuntime "com.fasterxml.jackson.core:jackson-annotations:$jacksonVersion"
- testRuntime project(':groovy-ant') // for JavadocAssertionTests
+ testRuntimeOnly "com.fasterxml.jackson.core:jackson-annotations:$jacksonVersion"
+ testRuntimeOnly project(':groovy-ant') // for JavadocAssertionTests
}
eclipse.classpath.file.whenMerged {