From 7341ead2aade10ea1b833e94275277658741883a Mon Sep 17 00:00:00 2001 From: Edoardo La Greca Date: Mon, 18 Aug 2025 21:09:11 +0200 Subject: switch to multi-module project structure --- buildSrc/src/main/kotlin/kotlin-jvm.gradle.kts | 29 ++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 buildSrc/src/main/kotlin/kotlin-jvm.gradle.kts (limited to 'buildSrc/src/main/kotlin') diff --git a/buildSrc/src/main/kotlin/kotlin-jvm.gradle.kts b/buildSrc/src/main/kotlin/kotlin-jvm.gradle.kts new file mode 100644 index 0000000..d11bbb9 --- /dev/null +++ b/buildSrc/src/main/kotlin/kotlin-jvm.gradle.kts @@ -0,0 +1,29 @@ +// The code in this file is a convention plugin - a Gradle mechanism for sharing reusable build logic. +// `buildSrc` is a Gradle-recognized directory and every plugin there will be easily available in the rest of the build. +package buildsrc.convention + +import org.gradle.api.tasks.testing.logging.TestLogEvent + +plugins { + // Apply the Kotlin JVM plugin to add support for Kotlin in JVM projects. + kotlin("jvm") +} + +kotlin { + // Use a specific Java version to make it easier to work in different environments. + jvmToolchain(21) +} + +tasks.withType().configureEach { + // Configure all test Gradle tasks to use JUnitPlatform. + useJUnitPlatform() + + // Log information about all test results, not only the failed ones. + testLogging { + events( + TestLogEvent.FAILED, + TestLogEvent.PASSED, + TestLogEvent.SKIPPED + ) + } +} -- cgit v1.2.3