From 5912e65434ab26cc0c9b12dbea4b4f59d4089308 Mon Sep 17 00:00:00 2001 From: Dawid Weiss Date: Wed, 26 May 2021 10:19:55 +0200 Subject: [PATCH] LUCENE-9974: The test-framework module should apply the test ruleset for forbidden APIs. (#153) --- gradle/validation/forbidden-apis.gradle | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/gradle/validation/forbidden-apis.gradle b/gradle/validation/forbidden-apis.gradle index 832dcde8940..5041e658414 100644 --- a/gradle/validation/forbidden-apis.gradle +++ b/gradle/validation/forbidden-apis.gradle @@ -136,5 +136,15 @@ allprojects { prj -> 'jdk-system-out' ] } + + // the test-framework module is special in that its main sources are exported for all tests. + // include the test signature file (defaults.tests.txt) to the main sourceset. + if (prj.path in [ + ":lucene:test-framework" + ]) { + forbiddenApisMain.signaturesFiles += files( + file("${resources}/defaults.tests.txt") + ) + } }) } \ No newline at end of file