1414 * limitations under the License.
1515 */
1616
17- plugins {
18- id(" eclipse" )
19- id(" idea" )
20-
21- alias(libs. plugins. bnd) apply false
22- alias(libs. plugins. detekt) apply false
23- alias(libs. plugins. dokka) apply false
24- alias(libs. plugins. download) apply false
25- alias(libs. plugins. kotlin) apply false
26- alias(libs. plugins. kotlin. serialization) apply false
27- alias(libs. plugins. optional) apply false
28- alias(libs. plugins. scala. multiversion) apply false
29- alias(libs. plugins. spotbugs) apply false
30- alias(libs. plugins. spotless) apply false
31- alias(libs. plugins. test. logger) apply false
17+ apply plugin : ' eclipse'
18+ apply plugin : ' idea'
19+
20+ buildscript {
21+ repositories {
22+ mavenLocal()
23+ mavenCentral()
24+ maven { url " https://plugins.gradle.org/m2/" }
25+ }
26+ dependencies {
27+ classpath ' com.netflix.nebula:gradle-extra-configurations-plugin:7.0.0'
28+ classpath " com.github.spotbugs.snom:spotbugs-gradle-plugin:6.0.15"
29+ classpath ' biz.aQute.bnd:biz.aQute.bnd.gradle:5.1.2'
30+
31+ // Scala plugins
32+ classpath " com.adtran:scala-multiversion-plugin:2.0.4"
33+ classpath " com.diffplug.spotless:spotless-plugin-gradle:6.14.0"
34+
35+ // kotlin plugins
36+ classpath " org.jetbrains.kotlin:kotlin-gradle-plugin:1.8.10"
37+ classpath " org.jetbrains.kotlin:kotlin-serialization:1.8.10"
38+ classpath " org.jetbrains.dokka:dokka-gradle-plugin:1.8.10"
39+ classpath " io.gitlab.arturbosch.detekt:detekt-gradle-plugin:1.21.0"
40+
41+ // Test logging plugin
42+ classpath ' com.adarshr:gradle-test-logger-plugin:2.1.0'
43+ }
3244}
3345
3446// ////////////////////////////////////////
@@ -37,6 +49,17 @@ plugins {
3749
3850ext {
3951 configDir = new File (rootDir, ' config' )
52+ jnrUnixsocketVersion = ' 0.38.17'
53+ nettyVersion = ' 4.1.87.Final'
54+ snappyVersion = ' 1.1.10.3'
55+ zstdVersion = ' 1.5.5-3'
56+ awsSdkV2Version = ' 2.18.9'
57+ awsSdkV1Version = ' 1.12.337'
58+ projectReactorVersion = ' 2022.0.0'
59+ junitBomVersion = ' 5.10.2'
60+ logbackVersion = ' 1.3.14'
61+ graalSdkVersion = ' 24.0.0'
62+ reflectionsVersion = ' 0.9.10'
4063 gitVersion = getGitVersion()
4164}
4265
@@ -86,21 +109,27 @@ configure(javaProjects) {
86109}
87110
88111configure(scalaProjects) {
89- apply plugin : " java-library"
90- apply plugin : " scala"
112+ apply plugin : ' scala'
113+ apply plugin : ' java-library'
114+ apply plugin : ' idea'
91115 apply plugin : " com.adtran.scala-multiversion-plugin"
92116 apply plugin : " com.diffplug.spotless"
93117
94118 group = ' org.mongodb.scala'
95119
96120 dependencies {
97- api(libs. scala. library)
98- api(libs. scala. reflect)
99-
100- testImplementation(platform(libs. junit. bom))
101- testImplementation(libs. bundles. junit. vintage)
102- testImplementation(libs. bundles. scalatest)
103- testImplementation(libs. reflections)
121+ api (' org.scala-lang:scala-library:%scala-version%' )
122+ api (' org.scala-lang:scala-reflect:%scala-version%' )
123+
124+ testImplementation(platform(" org.junit:junit-bom:$junitBomVersion " ))
125+ testImplementation(" org.junit.vintage:junit-vintage-engine" )
126+
127+ testImplementation(' org.scalatest:scalatest-flatspec_%%:3.2.9' )
128+ testImplementation(' org.scalatest:scalatest-shouldmatchers_%%:3.2.9' )
129+ testImplementation(' org.scalatestplus:junit-4-13_%%:3.2.9.0' )
130+ testImplementation(' org.scalatestplus:mockito-3-12_%%:3.2.10.0' )
131+ testImplementation(" ch.qos.logback:logback-classic:$logbackVersion " )
132+ testImplementation(" org.reflections:reflections:$reflectionsVersion " )
104133 }
105134
106135 test{
@@ -148,12 +177,12 @@ configure(javaMainProjects) {
148177 apply plugin : ' java-library'
149178
150179 dependencies {
151- compileOnly(libs. findbugs. jsr)
152- api(libs. slf4j, optional)
180+ compileOnly ' com.google.code.findbugs:jsr305:1.3.9'
181+ api ' org.slf4j:slf4j-api:1.7.6' , optional
182+ testImplementation ' com.google.code.findbugs:jsr305:1.3.9'
153183
154- testImplementation(libs. findbugs. jsr)
155184 // https://issues.apache.org/jira/browse/GROOVY-10194
156- testImplementation(libs . groovy)
185+ testImplementation ' org.codehaus. groovy:groovy-all:3.0.9 '
157186 }
158187
159188 /* Compiling */
@@ -222,19 +251,25 @@ configure(javaCodeCheckedProjects) {
222251 apply plugin : ' com.adarshr.test-logger'
223252
224253 dependencies {
225- testImplementation(platform(libs. junit. bom))
226- testImplementation(libs. bundles. junit. vintage)
227-
228- testImplementation(platform(libs. spock. bom))
229- testImplementation(libs. bundles. spock)
230-
254+ testImplementation(platform(" org.junit:junit-bom:$junitBomVersion " ))
255+ testImplementation(' org.junit.jupiter:junit-jupiter' )
256+ testImplementation(' org.junit.jupiter:junit-jupiter-params' )
257+ testImplementation(' org.junit.jupiter:junit-jupiter-engine' )
258+ testImplementation(' org.junit.vintage:junit-vintage-engine' )
259+
260+ testImplementation platform(' org.spockframework:spock-bom:2.1-groovy-3.0' )
261+ testImplementation ' org.spockframework:spock-core'
262+ testImplementation ' org.spockframework:spock-junit4'
231263 if (' 8' . equals(findProperty(" javaVersion" ))) {
232- testImplementation(libs. bundles. mockito. java8)
264+ testImplementation(" org.mockito:mockito-core:4.6.1" )
265+ testImplementation(" org.mockito:mockito-inline:4.6.1" )
233266 } else {
234- testImplementation(libs . bundles . mockito)
267+ testImplementation(" org. mockito:mockito-core:5.11.0 " )
235268 }
236- testImplementation(libs. cglib)
237- testImplementation(libs. objenesis)
269+ testImplementation ' cglib:cglib-nodep:2.2.2'
270+ testImplementation ' org.objenesis:objenesis:1.3'
271+ testImplementation ' org.hamcrest:hamcrest-all:1.3'
272+ testImplementation " ch.qos.logback:logback-classic:$logbackVersion "
238273 testImplementation project(' :util:spock' ) // Adding categories to classpath
239274 }
240275
0 commit comments