Skip to content

Commit

Permalink
Test with JDK13 (#68)
Browse files Browse the repository at this point in the history
  • Loading branch information
bsideup authored Oct 31, 2019
1 parent 363c716 commit 2ddf3fb
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ jobs:
- name: Set up JDK
uses: actions/setup-java@v1
with:
java-version: 11
java-version: 13
- name: Build with Gradle
run: ./gradlew check javadoc
9 changes: 9 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,15 @@ subprojects {
jcenter()
}

tasks.withType(Test).all {
def javaMajorVersion = System.getProperty("java.version").split("\\.", 2)[0].toInteger()
if (javaMajorVersion >= 13) {
jvmArgs += [
"-XX:+AllowRedefinitionToAddDeleteMethods"
]
}
}

plugins.withType(MavenPublishPlugin) {
project.publishing {
repositories {
Expand Down
2 changes: 1 addition & 1 deletion example/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ test {
// This is not required in normal testing scenarios
forkEvery = 1
maxParallelForks = 1
jvmArgs = [
jvmArgs += [
"-Xverify:all",
JavaVersion.current().isJava9Compatible()
? "-Xlog:redefine+class*=warning"
Expand Down

0 comments on commit 2ddf3fb

Please sign in to comment.