-
Notifications
You must be signed in to change notification settings - Fork 334
Expand file tree
/
Copy pathbuild.gradle
More file actions
62 lines (53 loc) · 1.86 KB
/
build.gradle
File metadata and controls
62 lines (53 loc) · 1.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
plugins {
id 'application'
id 'com.gradleup.shadow'
}
ext {
// This smoke test should be limited to Java 25 and above
// But the groovy testing framework cannot run on Java 25
// Using Java 8 for now and runs a JVM 25 when forking tests process.
// Relying on forked JVM 25 is hardcoded in the test suites (see createProcessBuilder()).
minJavaVersionForTests = JavaVersion.VERSION_1_8
maxJavaVersionForTests = JavaVersion.VERSION_1_8
}
apply from: "$rootDir/gradle/java.gradle"
description = 'JDK 25 Concurrent Integration Tests'
tasks.named('compileJava').configure {
setJavaVersion(it, 25)
sourceCompatibility = JavaVersion.VERSION_25
targetCompatibility = JavaVersion.VERSION_25
options.compilerArgs.add("--enable-preview")
javaToolchains {
java {
toolchain {
languageVersion = JavaLanguageVersion.of(25)
}
}
}
}
tasks.named('compileTestGroovy').configure {
setJavaVersion(it, 8)
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
// Disable plugin tasks that do not support Java 25:
// * forbiddenApis is missing classes
// * spotless as the google-java-format version does not support Java 25 and can't be changed once applied
// * spotbugs failed to read class using newer bytecode versions
forbiddenApisMain {
failOnMissingClasses = false
}
['spotlessApply', 'spotlessCheck', 'spotlessJava', 'spotbugsMain'].each {
tasks.named(it).configure { enabled = false }
}
application {
mainClass = 'datadog.smoketest.concurrent.ConcurrentApp'
}
dependencies {
implementation group: 'io.opentelemetry.instrumentation', name: 'opentelemetry-instrumentation-annotations', version: '2.19.0'
testImplementation project(':dd-smoke-tests')
}
tasks.withType(Test).configureEach {
dependsOn "shadowJar"
jvmArgs "-Ddatadog.smoketest.shadowJar.path=${tasks.shadowJar.archiveFile.get()}"
}