Skip to content

Conversation

@jselbo
Copy link
Contributor

@jselbo jselbo commented Oct 29, 2025

Fixes #3758

Possibly we could update the isMockConstruction predicate in InlineDelegateByteBuddyMockMaker to avoid this recursive trace. But it also seems to reasonable to do this - not allow mocking WeakReference at all. It's a simple type that shouldn't need to be mocked anyway.

Checklist

  • Read the contributing guide
  • PR should be motivated, i.e. what does it fix, why, and if relevant how
  • If possible / relevant include an example in the description, that could help all readers
    including project members to get a better picture of the change
  • Avoid other runtime dependencies
  • Meaningful commit history ; intention is important please rebase your commit history so that each
    commit is meaningful and help the people that will explore a change in 2 years
  • The pull request follows coding style (run ./gradlew spotlessApply for auto-formatting)
  • Mention Fixes #<issue number> in the description if relevant
  • At least one commit should end with Fixes #<issue number> if relevant

@codecov-commenter
Copy link

codecov-commenter commented Oct 29, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.41%. Comparing base (bf3a809) to head (f4baa04).
⚠️ Report is 3 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##               main    #3759      +/-   ##
============================================
- Coverage     86.44%   86.41%   -0.04%     
+ Complexity     2987     2986       -1     
============================================
  Files           341      341              
  Lines          9032     9041       +9     
  Branches       1112     1113       +1     
============================================
+ Hits           7808     7813       +5     
- Misses          943      944       +1     
- Partials        281      284       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Contributor

@TimvdLippe TimvdLippe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense to me 👍

@TimvdLippe TimvdLippe merged commit 58ba445 into mockito:main Oct 31, 2025
19 checks passed
dongjoon-hyun added a commit to apache/spark-kubernetes-operator that referenced this pull request Dec 10, 2025
### What changes were proposed in this pull request?

This PR aims to upgrade `mockito` to 5.21.0 for Apache Spark K8s Operator `v0.7`.

### Why are the changes needed?

To bring the latest features and bug fixes.
- https://github.com/mockito/mockito/releases/tag/v5.21.0
  - mockito/mockito#3758
  - mockito/mockito#3752
  - mockito/mockito#3753
  - mockito/mockito#3759
  - mockito/mockito#3731

### Does this PR introduce _any_ user-facing change?

No behavior change.

### How was this patch tested?

Pass the CIs.

### Was this patch authored or co-authored using generative AI tooling?

No.

Closes #425 from dongjoon-hyun/SPARK-54672.

Authored-by: Dongjoon Hyun <dongjoon@apache.org>
Signed-off-by: Dongjoon Hyun <dongjoon@apache.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

StackOverflowError when mocking WeakReference

3 participants