You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/topics/whatsnew2020.md
+21Lines changed: 21 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -584,6 +584,27 @@ By default, this property is set to `false` and the `apiElements` variant in Gra
584
584
We would appreciate your feedback on this new approach. Have you noticed any performance improvements while using it?
585
585
Let us know by adding a comment in [YouTrack](https://youtrack.jetbrains.com/issue/KT-61861/Gradle-Kotlin-compilations-depend-on-packed-artifacts).
586
586
587
+
### Aligned dependency behavior of Kotlin Gradle plugin with java-test-fixtures plugin
588
+
589
+
Prior to Kotlin 2.0.20, if you used the [`java-test-fixtures` plugin](https://docs.gradle.org/current/userguide/java_testing.html#sec:java_test_fixtures)
590
+
in your project, there was a difference between Gradle and the Kotlin Gradle plugin in how dependencies were propagated.
591
+
592
+
The Kotlin Gradle plugin propagated dependencies:
593
+
594
+
* From the `java-test-fixtures` plugin's `implementation` and `api` dependency types to the `test` source set compilation classpath.
595
+
* From the main source set's `implementation` and `api` dependency types to the `java-test-fixtures` plugin's source set compilation classpath.
596
+
597
+
However, Gradle only propagated dependencies in the `api` dependency types.
598
+
599
+
This difference in behavior led to some projects finding resource files multiple times in the classpath.
600
+
601
+
As of Kotlin 2.0.20, the Kotlin Gradle plugin's behavior is aligned with Gradle's `java-test-fixtures` plugin so this
602
+
problem no longer occurs for this or other Gradle plugins.
603
+
604
+
As a result of this change, some dependencies in the `test` and `testFixtures` source sets may no longer be accessible.
605
+
If this happens, either change the dependency declaration type from `implementation` to `api` or add a new dependency
606
+
declaration on the affected source set.
607
+
587
608
### Added task dependency for rare cases when the compile task lacks one on an artifact
588
609
589
610
Prior to 2.0.20, we found that there were scenarios where a compile task was missing a task dependency for one
0 commit comments