Skip to content

Mockito:5.14.2 Warning: Mockito is currently self-attaching... #3512

@maximkovalenko-hc

Description

@maximkovalenko-hc

Using mockito-core:5.14.2 and spring-boot:3.3.5 shows this warning:

Mockito is currently self-attaching to enable the inline-mock-maker. 
This will no longer work in future releases of the JDK. 
Please add Mockito as an agent to your build what is described in Mockito's documentation: https://javadoc.io/doc/org.mockito/mockito-core/latest/org/mockito/Mockito.html#0.3

image

However the previous versions of mockito (5.13.0, 5.12.0, 5.11.0...) don't have it.

Can we run the latest version of mockito without "Mockito is currently self-attaching..." warning?

More details:
mockito-core:5.14.2
mockito-junit-jupiter:5.14.2
spring-boot:3.3.5
Oracle GraalVM 21.0.5+9.1

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions