Skip to content

fix: do not mask exception#3797

Open
msvticket wants to merge 1 commit into
mockito:mainfrom
msvticket:dont-mask-exception
Open

fix: do not mask exception#3797
msvticket wants to merge 1 commit into
mockito:mainfrom
msvticket:dont-mask-exception

Conversation

@msvticket

@msvticket msvticket commented Mar 19, 2026

Copy link
Copy Markdown

Prevent exception to be thrown when generating exception message in moreThanOneMockCandidate.

Fixes #285 as far as I understand

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

@msvticket
msvticket force-pushed the dont-mask-exception branch from 8373bec to 85b7a0c Compare March 19, 2026 12:39
prevent exception to be thrown when generating exception message

Fixes mockito#285
@msvticket
msvticket force-pushed the dont-mask-exception branch from 85b7a0c to 72933af Compare March 19, 2026 12:42
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.

"Argument should be a mock, but is" error when combine @InjectMocks with @Spy

1 participant