This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to branch master
in repository
https://gitbox.apache.org/repos/asf/sling-org-apache-sling-junit-core.git
The following commit(s) were added to refs/heads/master by this push:
new 81ae642 SLING-12720 - Build fails on Java 21:Byte Buddy could not
instrument all classes within the mock's type hierarchy (#26)
81ae642 is described below
commit 81ae642acef4c5da82b78804356b52a520637a33
Author: Robert Munteanu <[email protected]>
AuthorDate: Thu Mar 27 23:29:13 2025 +0100
SLING-12720 - Build fails on Java 21:Byte Buddy could not instrument all
classes within the mock's type hierarchy (#26)
Update mockito and ASM to versions that support Java 21.
---
pom.xml | 4 ++--
.../org/apache/sling/junit/annotations/AnnotationsTestSupport.java | 7 ++++++-
2 files changed, 8 insertions(+), 3 deletions(-)
diff --git a/pom.xml b/pom.xml
index 9d9f22e..1331037 100644
--- a/pom.xml
+++ b/pom.xml
@@ -369,8 +369,8 @@
<dependency>
<groupId>org.mockito</groupId>
- <artifactId>mockito-inline</artifactId>
- <version>3.10.0</version>
+ <artifactId>mockito-core</artifactId>
+ <version>5.10.0</version>
<scope>test</scope>
</dependency>
diff --git
a/src/it/annotations-it/src/test/java/org/apache/sling/junit/annotations/AnnotationsTestSupport.java
b/src/it/annotations-it/src/test/java/org/apache/sling/junit/annotations/AnnotationsTestSupport.java
index de3e559..0ff64d8 100644
---
a/src/it/annotations-it/src/test/java/org/apache/sling/junit/annotations/AnnotationsTestSupport.java
+++
b/src/it/annotations-it/src/test/java/org/apache/sling/junit/annotations/AnnotationsTestSupport.java
@@ -83,7 +83,12 @@ public class AnnotationsTestSupport extends TestSupport {
mavenBundle().groupId("ch.qos.logback").artifactId("logback-core").versionAsInProject(),
mavenBundle().groupId("org.ops4j.pax.logging").artifactId("pax-logging-api").versionAsInProject(),
mavenBundle().groupId("org.ops4j.pax.logging").artifactId("pax-logging-logback").versionAsInProject(),
-
mavenBundle().groupId("jakarta.json").artifactId("jakarta.json-api").version("2.1.1")
+
mavenBundle().groupId("jakarta.json").artifactId("jakarta.json-api").version("2.1.1"),
+
mavenBundle().groupId("org.ow2.asm").artifactId("asm").version("9.7"),
+
mavenBundle().groupId("org.ow2.asm").artifactId("asm-analysis").version("9.7"),
+
mavenBundle().groupId("org.ow2.asm").artifactId("asm-commons").version("9.7"),
+
mavenBundle().groupId("org.ow2.asm").artifactId("asm-util").version("9.7"),
+
mavenBundle().groupId("org.ow2.asm").artifactId("asm-tree").version("9.7")
);
}