Upgrade Mockito 5.13.0 -> 5.14.0 (#1345)

And configure its Java agent such that Byte Buddy does not need to use
the deprecated self-attach mechanism.

See:
- https://github.com/mockito/mockito/releases/tag/v5.14.0
- https://github.com/mockito/mockito/compare/v5.13.0...v5.14.0
This commit is contained in:
Picnic-DevPla-Bot
2024-10-17 15:11:27 +02:00
committed by GitHub
parent ce18b0c058
commit 0bce1a0e29
2 changed files with 27 additions and 6 deletions

28
pom.xml
View File

@@ -111,6 +111,9 @@
but also prevents excessive memory usage by heavily parallelized
local builds. -->
-Xmx${argLine.xmx}
<!-- Configure the Byte Buddy Java agent used by Mockito to create
mocks. -->
-javaagent:${org.mockito:mockito-core:jar}
<!-- This argument cannot be set through Surefire's
'systemPropertyVariables' configuration setting. Setting the file
encoding is necessary because forked unit test invocations
@@ -213,7 +216,7 @@
<version.guava-beta-checker>1.0</version.guava-beta-checker>
<version.jdk>17</version.jdk>
<version.maven>3.9.9</version.maven>
<version.mockito>5.13.0</version.mockito>
<version.mockito>5.14.0</version.mockito>
<version.nopen-checker>1.0.1</version.nopen-checker>
<version.nullaway>0.11.3</version.nullaway>
<version.pitest-git>1.1.4</version.pitest-git>
@@ -523,6 +526,17 @@
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<!-- To avoid repetition of fairly complex configuration, Surefire
is configured to always load Mockito's Java agent. Declaring the
associated dependency here avoids additional repetition, and prevents
a slightly obscure error that happens if the dependency is absent. -->
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<pluginManagement>
@@ -1017,6 +1031,14 @@
<ignoreDirect>false</ignoreDirect>
<ignoreNonCompile>true</ignoreNonCompile>
</configuration>
<executions>
<execution>
<id>set-additional-properties</id>
<goals>
<goal>properties</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
@@ -1555,6 +1577,10 @@
<groupId>io.github.git-commit-id</groupId>
<artifactId>git-commit-id-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>

View File

@@ -88,10 +88,5 @@
<artifactId>junit-jupiter-params</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
</project>