From ff0e30c8852f137c67268bfb74a8691b9b2c2775 Mon Sep 17 00:00:00 2001 From: Stephan Schroevers Date: Thu, 9 Jan 2025 09:20:39 +0100 Subject: [PATCH] Make Mockito setup IntelliJ IDEA-compatible (#1500) See https://github.com/mockito/mockito/issues/3037#issuecomment-2569680756 --- README.md | 5 +++-- pom.xml | 12 +++++++++--- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 1826bbe3a2..76a4861440 100644 --- a/README.md +++ b/README.md @@ -235,8 +235,9 @@ Other highly relevant commands: against _all_ code in the current working directory. For more information check the [PIT Maven plugin][pitest-maven]. -When running the project's tests in IntelliJ IDEA, you might see the following -error: +Opening the project in IntelliJ IDEA may require running `mvn clean install` +first. Additionally, when running the project's tests using the IDE, you might +see the following error: ``` java: exporting a package from system module jdk.compiler is not allowed with --release diff --git a/pom.xml b/pom.xml index 8c8d7b3fdf..0b47ffcb94 100644 --- a/pom.xml +++ b/pom.xml @@ -113,7 +113,7 @@ -Xmx${argLine.xmx} - -javaagent:${org.mockito:mockito-core:jar} + -javaagent:${project.build.directory}/test-agents/mockito-core.jar