Repository navigation
TS-46356 Gradle plugin: Make the default excludes match Mockito mocks and Guice fast classes - #1003
Merged
DreierF merged 2 commits intoNov 4, 2026
Conversation
… and Guice fast classes Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…d_classes Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
DreierF
approved these changes
Nov 4, 2026
DreierF
deleted the
ts/46356_fix_default_excludes_for_generated_classes
branch
November 4, 2026 08:17
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Addresses issue TS-46356
The Gradle plugin's default JaCoCo excludes
*.MockitoMock.*and*.FastClassByGuice.*never matched. JaCoCo matches excludes against the JVM internal class name, in which these generated classes are joined by$(com/x/IFoo$MockitoMock$123,com/x/Foo$$FastClassByGuice$$abc). So the profiler instrumented every Mockito mock, and the testwise coverage report warned "Found coverage for N classes that were not provided".Changes
$:*$MockitoMock$*and*$$FastClassByGuice$$*.TeamscalePluginDefaultExcludesTestapplies the plugin and checks the excludes the way JaCoCo's agent does: both generated classes match, ordinary nested and anonymous classes (Foo$Bar,Foo$1) do not.Notes for the reviewer
Out of scope, noticed during triage:
jacoco.excludes?.addAll(DEFAULT_EXCLUDES)throws when a build sets the excludes to a read-only list (listOf(...)), and*.ConstructorAccesslikely has the same dot-separator flaw. Both deserve their own ticket.Teamscale's
ide/buildSrccarries a workaround for this bug (TS-46322); it can go once Teamscale uses a profiler release with this fix.Changes are tested adequately
Teamscale documentation updated in case of user-visible changes (not needed: no documented behavior changes)
CHANGELOG.md updated
Present new features in N&N (bug fix)
TGA Tutorial updated (not affected)
TIA Tutorial updated (not affected)
🤖 Generated with Claude Code