From b62b790bd54fe7f5c546d8fcf3b3232a6545aea2 Mon Sep 17 00:00:00 2001 From: Matthew Haughton <3flex@users.noreply.github.com> Date: Tue, 2 Aug 2022 13:42:01 +1000 Subject: [PATCH 1/2] Enable Gradle Enterprise Test Distribution plugin --- settings.gradle.kts | 1 + 1 file changed, 1 insertion(+) diff --git a/settings.gradle.kts b/settings.gradle.kts index 6bd4a0a283a..4abb8253fdc 100644 --- a/settings.gradle.kts +++ b/settings.gradle.kts @@ -44,6 +44,7 @@ plugins { // check https://gradle.com/enterprise/releases with new versions. GE plugin version should not lag behind Gradle version id("com.gradle.enterprise") version "3.10.3" id("com.gradle.common-custom-user-data-gradle-plugin") version "1.7.2" + id("com.gradle.enterprise.test-distribution") version "2.3.5" } val isCiBuild = System.getenv("CI") != null From 4a59f8cb6d59140426dbb1e53ab1ac8c865d8b65 Mon Sep 17 00:00:00 2001 From: Matthew Haughton <3flex@users.noreply.github.com> Date: Tue, 2 Aug 2022 13:42:19 +1000 Subject: [PATCH 2/2] Enable Predictive Test Selection for local builds --- build.gradle.kts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/build.gradle.kts b/build.gradle.kts index 15a04143a7f..70d1f966bfc 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -44,6 +44,14 @@ allprojects { } } +subprojects { + tasks.withType { + predictiveSelection { + enabled.set(System.getenv("CI") == null) + } + } +} + val analysisDir = file(projectDir) val baselineFile = file("$rootDir/config/detekt/baseline.xml") val configFile = file("$rootDir/config/detekt/detekt.yml")