From 373b3ddc006640b273db9f112950b06e87b5a8c1 Mon Sep 17 00:00:00 2001 From: Dariusz Seweryn Date: Sun, 10 Mar 2024 19:01:38 +0100 Subject: [PATCH] Added jupiter setup. --- dependencies.gradle | 5 ++++- gradle/src-gen-rxjava3-from-rxjava2.gradle | 2 +- rxandroidble/build.gradle | 2 ++ rxandroidble3/build.gradle | 2 ++ 4 files changed, 9 insertions(+), 2 deletions(-) diff --git a/dependencies.gradle b/dependencies.gradle index f9c899b1c..d34c65123 100644 --- a/dependencies.gradle +++ b/dependencies.gradle @@ -6,6 +6,7 @@ ext { targetCompatibilityVersion = JavaVersion.VERSION_1_8 shadowPluginVersion = '7.1.2' daggerVersion = '2.42' + junitVersion = '5.10.2' libs = [ /* Library-only dependencies */ rxjava2 : "io.reactivex.rxjava2:rxjava:$rxJava2Version", @@ -13,7 +14,9 @@ ext { rxandroid : 'io.reactivex.rxjava2:rxandroid:2.1.1', rxrelay2 : 'com.jakewharton.rxrelay2:rxrelay:2.1.1', rxrelay3 : 'com.jakewharton.rxrelay3:rxrelay:3.0.1', - junit : 'org.junit.jupiter:junit-jupiter:5.8.1', + junit : ["org.junit.jupiter:junit-jupiter:$junitVersion", 'org.junit.jupiter:junit-jupiter'], + junit_platform : "org.junit:junit-bom:$junitVersion", + junit_runtime : 'org.junit.platform:junit-platform-launcher', groovy : ['org.codehaus.groovy:groovy:3.0.9', 'org.codehaus.groovy:groovy-test:3.0.9'], spock : 'org.spockframework:spock-core:2.0-groovy-3.0', dagger : "com.google.dagger:dagger:$daggerVersion", diff --git a/gradle/src-gen-rxjava3-from-rxjava2.gradle b/gradle/src-gen-rxjava3-from-rxjava2.gradle index 140525e43..283118a85 100644 --- a/gradle/src-gen-rxjava3-from-rxjava2.gradle +++ b/gradle/src-gen-rxjava3-from-rxjava2.gradle @@ -1,4 +1,4 @@ -// generates sources compatible with RxJava 2 to RxJava 3 +// copies and transforms sources compatible with RxJava 2 to RxJava 3 copy { from "../${project.name.substring(0, project.name.length() - 1)}/src" diff --git a/rxandroidble/build.gradle b/rxandroidble/build.gradle index b3b772478..84374a405 100644 --- a/rxandroidble/build.gradle +++ b/rxandroidble/build.gradle @@ -65,6 +65,8 @@ dependencies { // Test dependencies testImplementation rootProject.ext.libs.junit + testImplementation platform(rootProject.ext.libs.junit_platform) testImplementation rootProject.ext.libs.groovy testImplementation rootProject.ext.libs.spock + testRuntimeOnly rootProject.ext.libs.junit_runtime } diff --git a/rxandroidble3/build.gradle b/rxandroidble3/build.gradle index 115b16375..47704942d 100644 --- a/rxandroidble3/build.gradle +++ b/rxandroidble3/build.gradle @@ -68,6 +68,8 @@ dependencies { // Test dependencies testImplementation files(tasks.getByPath(':dagger-library-shadow:shadowJar').archiveFile) testImplementation rootProject.ext.libs.junit + testImplementation platform(rootProject.ext.libs.junit_platform) testImplementation rootProject.ext.libs.groovy testImplementation rootProject.ext.libs.spock + testRuntimeOnly rootProject.ext.libs.junit_runtime }