From bfa17d3fc75700494aac81b26822a76c436fddb6 Mon Sep 17 00:00:00 2001 From: Christian Beikov Date: Mon, 19 Sep 2022 14:51:06 +0200 Subject: [PATCH] Allow excluding tests of all sub projects, not just hibernate-core --- gradle/java-module.gradle | 7 +++++++ hibernate-core/hibernate-core.gradle | 7 ------- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/gradle/java-module.gradle b/gradle/java-module.gradle index 34167c593a..ce0bf030a5 100644 --- a/gradle/java-module.gradle +++ b/gradle/java-module.gradle @@ -278,6 +278,13 @@ tasks.withType( Test.class ).each { test -> if ( project.name != 'hibernate-testing' ) { test.dependsOn ':hibernate-testing:test' } + + // Allow to exclude specific tests + if ( project.hasProperty( 'excludeTests' ) ) { + test.filter { + excludeTestsMatching project.property('excludeTests').toString() + } + } } sourceSets { diff --git a/hibernate-core/hibernate-core.gradle b/hibernate-core/hibernate-core.gradle index 8dbb4be8b0..b9ca8b114b 100644 --- a/hibernate-core/hibernate-core.gradle +++ b/hibernate-core/hibernate-core.gradle @@ -203,13 +203,6 @@ tasks.withType( Test.class ).each { test -> test.beforeTest { descriptor -> //println "Starting test: " + descriptor } - - // Allow to exclude specific tests - if (project.hasProperty('excludeTests')) { - test.filter { - excludeTestsMatching project.property('excludeTests').toString() - } - } } // Tests with records