Add opt-in Paper integration tests

This commit is contained in:
2026-09-26 23:48:35 -07:00
parent 1721349a71
commit 1eab80ab2b
3 changed files with 148 additions and 1 deletions

View File

@@ -27,6 +27,18 @@ dependencies {
testRuntimeOnly 'org.junit.platform:junit-platform-launcher:1.13.4'
}
sourceSets {
integrationTest {
compileClasspath += sourceSets.main.output
runtimeClasspath += sourceSets.main.output
}
}
configurations {
integrationTestImplementation.extendsFrom testImplementation
integrationTestRuntimeOnly.extendsFrom testRuntimeOnly
}
java {
toolchain {
languageVersion = JavaLanguageVersion.of(25)
@@ -54,6 +66,15 @@ tasks.named('test') {
useJUnitPlatform()
}
tasks.register('integrationTest', Test) {
description = 'Runs opt-in tests against a running Paper server with RCON enabled.'
group = 'verification'
testClassesDirs = sourceSets.integrationTest.output.classesDirs
classpath = sourceSets.integrationTest.runtimeClasspath
useJUnitPlatform()
shouldRunAfter tasks.named('test')
}
tasks.named('wrapper') {
gradleVersion = '9.8.0'
distributionType = Wrapper.DistributionType.BIN