|
39 | 39 |
|
40 | 40 | <!-- Dependency versions, matched to Spring Boot --> |
41 | 41 | <aspectj.version>1.9.22.1</aspectj.version> |
42 | | - <httpcore5.version>5.2.5</httpcore5.version> |
| 42 | + <httpcore5.version>5.3.1</httpcore5.version> |
43 | 43 | <slf4j.version>2.0.16</slf4j.version> |
44 | | - <spring.version>6.1.14</spring.version> |
| 44 | + <spring.version>6.2.0</spring.version> |
45 | 45 |
|
46 | 46 | <!-- Test dependency versions --> |
47 | | - <spt-development-test.version>3.1.12</spt-development-test.version> |
| 47 | + <spt-development-test.version>3.1.13</spt-development-test.version> |
48 | 48 |
|
49 | 49 | <!-- Test dependency versions, matched to Spring Boot --> |
50 | 50 | <hamcrest.version>2.2</hamcrest.version> |
51 | | - <junit-jupiter.version>5.10.5</junit-jupiter.version> |
52 | | - <logback.version>1.5.8</logback.version> |
53 | | - <mockito.version>5.11.0</mockito.version> |
| 51 | + <junit-jupiter.version>5.11.3</junit-jupiter.version> |
| 52 | + <logback.version>1.5.12</logback.version> |
| 53 | + <mockito.version>5.14.2</mockito.version> |
54 | 54 |
|
55 | 55 | <!-- Plugin versions --> |
56 | 56 | <build-helper-maven-plugin.version>3.6.0</build-helper-maven-plugin.version> |
|
62 | 62 | <maven-dependency-plugin.version>3.8.1</maven-dependency-plugin.version> |
63 | 63 | <maven-enforcer-plugin.version>3.5.0</maven-enforcer-plugin.version> |
64 | 64 | <maven-gpg-plugin.version>3.2.7</maven-gpg-plugin.version> |
65 | | - <maven-javadoc-plugin.version>3.10.1</maven-javadoc-plugin.version> |
| 65 | + <maven-javadoc-plugin.version>3.11.1</maven-javadoc-plugin.version> |
66 | 66 | <maven-jxr-plugin.version>3.6.0</maven-jxr-plugin.version> |
67 | 67 | <maven-pmd-plugin.version>3.26.0</maven-pmd-plugin.version> |
68 | 68 | <maven-release-plugin.version>3.1.1</maven-release-plugin.version> |
69 | 69 | <maven-scm-plugin.version>2.1.0</maven-scm-plugin.version> |
70 | 70 | <maven-source-plugin.version>3.3.1</maven-source-plugin.version> |
71 | | - <maven-surefire-plugin.version>3.5.1</maven-surefire-plugin.version> |
| 71 | + <maven-surefire-plugin.version>3.5.2</maven-surefire-plugin.version> |
72 | 72 | <nexus-staging-plugin.version>1.7.0</nexus-staging-plugin.version> |
73 | | - <pitest-maven.version>1.17.0</pitest-maven.version> |
74 | | - <spotbugs.version>4.8.6.5</spotbugs.version> |
75 | | - <versions-maven-plugin.version>2.17.1</versions-maven-plugin.version> |
| 73 | + <pitest-maven.version>1.17.1</pitest-maven.version> |
| 74 | + <spotbugs.version>4.8.6.6</spotbugs.version> |
| 75 | + <versions-maven-plugin.version>2.18.0</versions-maven-plugin.version> |
76 | 76 |
|
77 | 77 | <!-- Plugin dependencies --> |
78 | | - <checkstyle.version>10.20.0</checkstyle.version> |
| 78 | + <checkstyle.version>10.20.1</checkstyle.version> |
79 | 79 | <findbugs-slf4j-bug-pattern.version>1.5.0</findbugs-slf4j-bug-pattern.version> |
80 | 80 | <findbugs-sec-bug-pattern.version>1.13.0</findbugs-sec-bug-pattern.version> |
81 | 81 | <pitest-junit5-plugin.version>1.2.1</pitest-junit5-plugin.version> |
|
331 | 331 | <ignoreAllNonTestScoped>true</ignoreAllNonTestScoped> |
332 | 332 | </configuration> |
333 | 333 | </execution> |
| 334 | + <!-- Required for Mockito as of JDK 21 - see `maven-surefire-plugin` configuration for more information. --> |
| 335 | + <execution> |
| 336 | + <goals> |
| 337 | + <goal>properties</goal> |
| 338 | + </goals> |
| 339 | + </execution> |
334 | 340 | </executions> |
335 | 341 | </plugin> |
336 | 342 | <plugin> |
|
414 | 420 | WARNING: Dynamic loading of agents will be disallowed by default in a future release |
415 | 421 |
|
416 | 422 | NOTE. argLine property is set by JaCoCo in prepare-agent stage. |
| 423 | +
|
| 424 | + Starting from Java 21, the JDK restricts the ability of libraries to attach a Java agent to their own JVM. As a result, the inline-mock-maker might not be |
| 425 | + able to function without an explicit setup to enable instrumentation, and the JVM will always display a warning. |
| 426 | +
|
| 427 | + To explicitly attach Mockito during test execution, the library's jar file needs to be specified as -javaagent as an argument to the executing JVM with |
| 428 | +
|
| 429 | + @{argLine} -javaagent:${org.mockito:mockito-core:jar} |
| 430 | +
|
| 431 | + Additionally, the `properties` goal of the `maven-dependency-plugin` must be executed. |
417 | 432 | --> |
418 | | - <argLine>-XX:+EnableDynamicAgentLoading ${argLine}</argLine> |
| 433 | + <argLine>-XX:+EnableDynamicAgentLoading @{argLine} -javaagent:${org.mockito:mockito-core:jar}</argLine> |
419 | 434 | <trimStackTrace>false</trimStackTrace> |
420 | 435 | <includes> |
421 | 436 | <include>**/*Tests.java</include> |
|
431 | 446 | <artifactId>spotbugs-maven-plugin</artifactId> |
432 | 447 | <version>${spotbugs.version}</version> |
433 | 448 | <dependencies> |
| 449 | + <!-- |
| 450 | + Added slf4j dependencies to resolve warning: |
| 451 | +
|
| 452 | + SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder". |
| 453 | + ... |
| 454 | + --> |
| 455 | + <dependency> |
| 456 | + <groupId>org.slf4j</groupId> |
| 457 | + <artifactId>slf4j-api</artifactId> |
| 458 | + <version>${slf4j.version}</version> |
| 459 | + </dependency> |
| 460 | + <dependency> |
| 461 | + <groupId>org.slf4j</groupId> |
| 462 | + <artifactId>slf4j-simple</artifactId> |
| 463 | + <version>${slf4j.version}</version> |
| 464 | + </dependency> |
| 465 | + |
434 | 466 | <!-- Included as dependencies as well as plugins so that versions plugins picks up new versions --> |
435 | 467 | <dependency> |
436 | 468 | <groupId>jp.skypencil.findbugs.slf4j</groupId> |
|
0 commit comments