This is an automated email from the ASF dual-hosted git repository. jdaugherty pushed a commit to branch gradle-deprecations in repository https://gitbox.apache.org/repos/asf/grails-core.git
commit 20d9f097b4ec5800c61f9065d63db56bd496aa89 Author: James Daugherty <[email protected]> AuthorDate: Wed Jun 4 12:17:32 2025 -0400 The IdeaModule.testSourceDirs property has been deprecated --- .../gradle/plugin/core/IntegrationTestGradlePlugin.groovy | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/grails-gradle/plugins/src/main/groovy/org/grails/gradle/plugin/core/IntegrationTestGradlePlugin.groovy b/grails-gradle/plugins/src/main/groovy/org/grails/gradle/plugin/core/IntegrationTestGradlePlugin.groovy index dd13f3d1f4..e3647b5467 100644 --- a/grails-gradle/plugins/src/main/groovy/org/grails/gradle/plugin/core/IntegrationTestGradlePlugin.groovy +++ b/grails-gradle/plugins/src/main/groovy/org/grails/gradle/plugin/core/IntegrationTestGradlePlugin.groovy @@ -32,6 +32,8 @@ import org.gradle.api.tasks.TaskProvider import org.gradle.api.tasks.testing.Test import org.gradle.api.tasks.testing.TestReport import org.gradle.language.base.plugins.LifecycleBasePlugin +import org.gradle.plugins.ide.idea.model.IdeaModel +import org.gradle.plugins.ide.idea.model.IdeaModule import org.grails.gradle.plugin.util.SourceSets import static org.gradle.api.plugins.JavaPlugin.TEST_IMPLEMENTATION_CONFIGURATION_NAME @@ -44,7 +46,6 @@ import static org.gradle.api.tasks.SourceSet.TEST_SOURCE_SET_NAME * * Adds integrationTestImplementation and integrationTestRuntimeOnly configurations that extend from testCompileClasspath and testRuntimeClasspath * - * */ @CompileStatic class IntegrationTestGradlePlugin implements Plugin<Project> { @@ -134,12 +135,11 @@ class IntegrationTestGradlePlugin implements Plugin<Project> { } @CompileDynamic - private integrateIdea(Project project, File[] acceptedSourceDirs) { + private void integrateIdea(Project project, File[] acceptedSourceDirs) { project.pluginManager.withPlugin('idea') { -> - project.idea { - module { - testSourceDirs += acceptedSourceDirs - } + def ideaExtension = project.getExtensions().getByType(IdeaModel) + ideaExtension.module { IdeaModule it -> + it.testSources.from(acceptedSourceDirs) } } }
