[Gradle] Setup Consistent metadata dependencies resolution

Configure consistent metadata resolution only for source sets that
participate in metadata compilation. i.e. test or any other extra
compilations should be excluded.

^KT-65954 Verification Pending
^KT-66047 Verification Pending
This commit is contained in:
Anton Lakotka
2024-02-21 09:32:08 +01:00
committed by Space Team
parent c027ba642f
commit 3e5afcaaba
13 changed files with 283 additions and 58 deletions
@@ -1282,7 +1282,8 @@ open class HierarchicalMppIT : KGPBaseTest() {
gradleVersion,
localRepoDir = tempDir,
).run {
// add a dependency from commonTest on 2.0 version
// add a dependency from jvmTest on 2.0 version
// and assert that this dependency isn't leaking to the main source sets, including metadata compilation
buildGradleKts.appendText(
"""