@@ -48,6 +48,13 @@ sourceSets {
4848 }
4949 }
5050
51+ test25 {
52+ java {
53+ compileClasspath + = main. output + test. output
54+ runtimeClasspath + = test. output
55+ srcDir(files(" src/test/jdk25" ))
56+ }
57+ }
5158}
5259
5360dependencies {
@@ -63,10 +70,17 @@ dependencies {
6370 builtBy compileJava
6471 }
6572
73+ java25Implementation project(' :prov' )
74+ java25Implementation project(' :util' )
75+ java25Implementation project(' :pkix' )
76+ java25Implementation files([sourceSets. main. output. classesDirs, sourceSets. java9. output]) {
77+ builtBy compileJava
78+ }
79+
6680 test11Implementation group : ' junit' , name : ' junit' , version : ' 4.13.2'
6781 test15Implementation group : ' junit' , name : ' junit' , version : ' 4.13.2'
6882 test21Implementation group : ' junit' , name : ' junit' , version : ' 4.13.2'
69-
83+ test25Implementation group : ' junit ' , name : ' junit ' , version : ' 4.13.2 '
7084
7185 test11Implementation project(' :prov' )
7286 test11Implementation project(' :util' )
@@ -80,6 +94,9 @@ dependencies {
8094 test21Implementation project(' :util' )
8195 test21Implementation project(' :pkix' )
8296
97+ test25Implementation project(' :prov' )
98+ test25Implementation project(' :util' )
99+ test25Implementation project(' :pkix' )
83100}
84101
85102
@@ -124,6 +141,21 @@ compileTest21Java {
124141 options. sourcepath = files([' src/test/java' , ' src/test/jdk21' ])
125142}
126143
144+ compileJava25Java {
145+
146+ options. release = 25
147+
148+ def prov_jar= " ${ project(":prov").jar.outputs.files.getFiles().getAt(0)} "
149+ def util_jar= " ${ project(":util").jar.outputs.files.getFiles().getAt(0)} "
150+ def pkix_jar= " ${ project(":pkix").jar.outputs.files.getFiles().getAt(0)} "
151+
152+
153+ options. compilerArgs + = [
154+ ' --module-path' , " ${ prov_jar}${ File.pathSeparator}${ util_jar}${ File.pathSeparator}${ pkix_jar} "
155+ ]
156+
157+ options. sourcepath = files([' src/main/java' , ' src/main/jdk25' ])
158+ }
127159
128160
129161task sourcesJar (type : Jar ) {
@@ -144,6 +176,9 @@ jar {
144176 into(' META-INF/versions/9' ) {
145177 from sourceSets. java9. output
146178 }
179+ into(' META-INF/versions/25' ) {
180+ from sourceSets. java25. output
181+ }
147182 String v = " ${ rootProject.extensions.ext.bundle_version} "
148183 manifest. attributes(' Multi-Release' : ' true' )
149184 manifest. attributes(' Bundle-Name' : ' bctls' )
@@ -321,8 +356,8 @@ task test25(type: Test) {
321356 onlyIf {System . getenv(" BC_JDK25" ) != null }
322357 dependsOn jar
323358
324- testClassesDirs = sourceSets. test21 . output. classesDirs
325- classpath = sourceSets. test21 . runtimeClasspath + files(jar. archiveFile)
359+ testClassesDirs = sourceSets. test25 . output. classesDirs
360+ classpath = sourceSets. test25 . runtimeClasspath + files(jar. archiveFile)
326361
327362 forkEvery = 1 ;
328363 maxParallelForks = 8 ;
0 commit comments