Skip to content
This repository was archived by the owner on Apr 2, 2021. It is now read-only.

Commit 47d8edc

Browse files
committed
Update gradle to 6.0 and validate gradle wrapper
See: https://github.com/gradle/wrapper-validation-action
1 parent e9f3cb1 commit 47d8edc

25 files changed

+161
-26
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
name: "Validate Gradle Wrapper"
2+
on: [push, pull_request]
3+
4+
jobs:
5+
validation:
6+
name: "Validation"
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v2
10+
- uses: gradle/wrapper-validation-action@v1

.travis.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ env:
99
- TEST_CATEGORY=fullCompileTests
1010
- TEST_CATEGORY=runProjectTests
1111
- TEST_CATEGORY=proxyTest
12+
before_script:
13+
- echo $JAVA_OPTS
14+
- export JAVA_OPTS=-Xmx4G
1215
script: "./gradlew --stacktrace check -PTEST_CATEGORY=$TEST_CATEGORY"
1316
branches:
1417
only:

build.gradle

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ sourceSets {
6262
resources {
6363
srcDir file('src/functionalTest/resources')
6464
}
65-
compileClasspath += sourceSets.main.output + configurations.testRuntime
65+
compileClasspath += sourceSets.main.output + configurations.testRuntimeClasspath
6666
runtimeClasspath += output + compileClasspath
6767
}
6868
}
@@ -129,7 +129,7 @@ idea {
129129
* Compiles the tests
130130
*/
131131
compileFunctionalTestGroovy {
132-
classpath += configurations.proxyTest
132+
classpath += configurations.proxyTest + configurations.testRuntimeClasspath
133133
}
134134

135135
/**
@@ -154,6 +154,7 @@ processResources {
154154
])
155155
}
156156
}
157+
duplicatesStrategy = DuplicatesStrategy.INCLUDE
157158
}
158159

159160

@@ -404,7 +405,7 @@ pluginBundle {
404405
*
405406
**********************************************************************************************************************/
406407
wrapper {
407-
gradleVersion = '5.6'
408+
gradleVersion = '6.0'
408409
distributionUrl = distributionUrl.replace('bin', 'all') // Download sources
409410
}
410411

gradle/wrapper/gradle-wrapper.jar

3.01 KB
Binary file not shown.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6-all.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-6.0-all.zip
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists

gradlew

Lines changed: 12 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -154,19 +154,19 @@ if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
154154
else
155155
eval `echo args$i`="\"$arg\""
156156
fi
157-
i=$((i+1))
157+
i=`expr $i + 1`
158158
done
159159
case $i in
160-
(0) set -- ;;
161-
(1) set -- "$args0" ;;
162-
(2) set -- "$args0" "$args1" ;;
163-
(3) set -- "$args0" "$args1" "$args2" ;;
164-
(4) set -- "$args0" "$args1" "$args2" "$args3" ;;
165-
(5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
166-
(6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
167-
(7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
168-
(8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
169-
(9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
160+
0) set -- ;;
161+
1) set -- "$args0" ;;
162+
2) set -- "$args0" "$args1" ;;
163+
3) set -- "$args0" "$args1" "$args2" ;;
164+
4) set -- "$args0" "$args1" "$args2" "$args3" ;;
165+
5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
166+
6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
167+
7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
168+
8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
169+
9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
170170
esac
171171
fi
172172

@@ -175,14 +175,9 @@ save () {
175175
for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
176176
echo " "
177177
}
178-
APP_ARGS=$(save "$@")
178+
APP_ARGS=`save "$@"`
179179

180180
# Collect all arguments for the java command, following the shell quoting and substitution rules
181181
eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
182182

183-
# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong
184-
if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
185-
cd "$(dirname "$0")"
186-
fi
187-
188183
exec "$JAVACMD" "$@"

src/functionalTest/groovy/com/devsoap/plugin/tests/GradleVersionTest.groovy

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class GradleVersionTest extends IntegrationTest {
2222

2323
@Parameterized.Parameters(name = "Gradle {0}")
2424
static Collection<String> getGradleVersions() {
25-
[ '5.6']
25+
[ '6.0']
2626
}
2727

2828
@Override

src/functionalTest/groovy/com/devsoap/plugin/tests/KotlinTest.groovy

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ class KotlinTest extends KotlinIntegrationTest {
2828

2929
@Parameterized.Parameters(name = "Kotlin {0}")
3030
static Collection<String> getKotlinVersions() {
31-
[ '1.3.11']
31+
[ '1.3.70']
3232
}
3333

3434
@Test void 'Create project'() {

src/main/groovy/com/devsoap/plugin/GradleVaadinPlugin.groovy

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ class GradleVaadinPlugin implements Plugin<Project> {
212212

213213
Gradle gradle = project.gradle
214214
VersionNumber version = VersionNumber.parse(gradle.gradleVersion)
215-
VersionNumber requiredVersion = new VersionNumber(5, 6, 0, null)
215+
VersionNumber requiredVersion = new VersionNumber(6, 0, 0, null)
216216
if ( version.baseVersion < requiredVersion ) {
217217
throw new UnsupportedVersionException("Your gradle version ($version) is too old. " +
218218
"Plugin requires Gradle $requiredVersion+")

src/main/groovy/com/devsoap/plugin/tasks/BuildClassPathJar.groovy

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ import com.devsoap.plugin.Util
2020
import org.gradle.api.file.FileCollection
2121
import org.gradle.api.provider.Property
2222
import org.gradle.api.provider.Provider
23+
import org.gradle.api.tasks.Input
2324
import org.gradle.api.tasks.bundling.Jar
2425

2526
/**
@@ -32,6 +33,7 @@ class BuildClassPathJar extends Jar {
3233

3334
public static final String NAME = 'vaadinClassPathJar'
3435

36+
@Input
3537
private final Property<Boolean> useClassPathJar = project.objects.property(Boolean)
3638

3739
BuildClassPathJar() {
@@ -51,7 +53,7 @@ class BuildClassPathJar extends Jar {
5153
project.configurations[GradleVaadinPlugin.CONFIGURATION_RUN_SERVER] +
5254
project.configurations[GradleVaadinPlugin.CONFIGURATION_THEME]
5355
)
54-
.filter { it.file && it.canonicalFile.name.endsWith('.jar')}
56+
.filter { it.file && it.canonicalFile.name.endsWith('.jar') }
5557
manifest {
5658
it.attributes('Class-Path':files.collect { File file -> file.toURI().toString() }.join(' '))
5759
}

0 commit comments

Comments
 (0)