Skip to content
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

Deep Stubs Incompatible With Mocking Enum #3167

Merged
merged 1 commit into from
Nov 29, 2023

Commits on Nov 29, 2023

  1. Deep Stubs Incompatible With Mocking Enum

    Mockito can't mock abstract enums in Java 15 or later
    because they are now marked as sealed.
    So Mockito reports that now with a better error message.
    
    If a deep stub returns an abstract enum, it uses in the error
    case now the first enum literal of the real enum.
    
    Fixes mockito#2984
    AndreasTu committed Nov 29, 2023
    Configuration menu
    Copy the full SHA
    b4bea3e View commit details
    Browse the repository at this point in the history