-
-
Notifications
You must be signed in to change notification settings - Fork 424
Add more docs and tests for DuplicatesStrategy
#1553
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
658fbfb to
f557e93
Compare
9e55db3 to
1865e85
Compare
DuplicatesStrategyDuplicatesStrategy
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
d53e043 to
251d55d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR enhances documentation and test coverage for the DuplicatesStrategy functionality in ShadowJar tasks, following up on issue #1349. The changes improve clarity around how duplicate file handling works and provide comprehensive examples.
- Adds detailed documentation for the
getDuplicatesStrategy()method with examples of each strategy type - Adds functional tests demonstrating how to override the duplicates strategy using
eachFileandfilesMatching - Updates existing documentation to clarify interactions between
ResourceTransformers andduplicatesStrategy
Reviewed Changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| ShadowJar.kt | Adds comprehensive KDoc for getDuplicatesStrategy() method with strategy examples and transformer interaction notes |
| ServiceFileTransformerTest.kt | Adds tests for overriding EXCLUDE strategy using eachFile and filesMatching, fixes line separator handling |
| ShadowJarCachingTest.kt | Fixes test setup by using writeText instead of appendText to prevent accumulating configurations |
| merging/README.md | Enhances documentation with clearer examples of strategy override techniques and additional reference links |
| shadow.api | Updates API surface to include the newly documented getDuplicatesStrategy() method |
ResourceTransformerandDuplicatesStrategy#1349.