Skip to content

Conversation

@fm2003
Copy link
Collaborator

@fm2003 fm2003 commented Jun 25, 2025

A student wrote this:

class SecurityScannerTest {
    private SecurityOfficer securityOfficer;
    // ...

    private SecurityScanner scanner;

    @BeforeEach
    public void setUp() {
        securityOfficer = mock();
        // ...
    }
}

This is now valid Mockito syntax, so we want to make sure that we detect such a way to create a mock of a class (in this case the SecurityOfficer class).

@fm2003 fm2003 merged commit edb90cc into main Jun 30, 2025
16 checks passed
@fm2003 fm2003 deleted the support-parameterless-mock branch June 30, 2025 16:18
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.

2 participants