This is an automated email from the ASF dual-hosted git repository.
apelluru pushed a commit to branch SLING-12072
in repository
https://gitbox.apache.org/repos/asf/sling-org-apache-sling-junit-core.git
The following commit(s) were added to refs/heads/SLING-12072 by this push:
new 82d3164 SLING-12072: migrate to jakarta.json
82d3164 is described below
commit 82d3164ceb721054b59b498c56e09dd2d234d387
Author: Ashok Pelluru <[email protected]>
AuthorDate: Wed Oct 4 10:54:12 2023 +0200
SLING-12072: migrate to jakarta.json
---
pom.xml | 37 ++++++++++++++++------
.../sling/junit/impl/servlet/JsonRenderer.java | 6 ++--
2 files changed, 30 insertions(+), 13 deletions(-)
diff --git a/pom.xml b/pom.xml
index 8b4be3f..ad52927 100644
--- a/pom.xml
+++ b/pom.xml
@@ -23,7 +23,7 @@
<parent>
<groupId>org.apache.sling</groupId>
<artifactId>sling-bundle-parent</artifactId>
- <version>43</version>
+ <version>52</version>
<relativePath />
</parent>
@@ -34,12 +34,10 @@
<description>Runs JUnit tests in an OSGi framework and provides the JUnit
libraries</description>
<properties>
- <junit.version>4.13</junit.version>
+ <junit.version>4.13.2</junit.version>
<hamcrest.version>1.3</hamcrest.version>
<jacoco.version>0.6.2.201302030002</jacoco.version>
- <junit-jupiter.version>5.6.0</junit-jupiter.version>
- <maven.compiler.source>1.8</maven.compiler.source>
- <maven.compiler.target>1.8</maven.compiler.target>
+ <junit-jupiter.version>5.10.0</junit-jupiter.version>
</properties>
<scm>
@@ -207,9 +205,20 @@
<version>19.0.0</version>
<scope>provided</scope>
</dependency>
+ <dependency>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.resource</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.util.tracker</artifactId>
+ <scope>provided</scope>
+ </dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.annotation.versioning</artifactId>
+ <scope>provided</scope>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
@@ -220,26 +229,33 @@
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.service.component</artifactId>
+ <scope>provided</scope>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.service.component.annotations</artifactId>
+ <scope>provided</scope>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.framework</artifactId>
+ <scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
+ <scope>provided</scope>
</dependency>
<dependency>
- <groupId>org.apache.sling</groupId>
- <artifactId>org.apache.sling.servlets.annotations</artifactId>
+ <groupId>jakarta.json</groupId>
+ <artifactId>jakarta.json-api</artifactId>
+ <version>2.0.2</version>
+ <scope>provided</scope>
</dependency>
<dependency>
- <groupId>org.osgi</groupId>
- <artifactId>osgi.core</artifactId>
+ <groupId>org.apache.sling</groupId>
+ <artifactId>org.apache.sling.servlets.annotations</artifactId>
+ <scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.geronimo.specs</groupId>
@@ -283,6 +299,7 @@
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.commons.osgi</artifactId>
<version>2.4.2</version>
+ <scope>provided</scope>
</dependency>
<dependency>
@@ -296,7 +313,7 @@
<dependency>
<groupId>org.junit.platform</groupId>
<artifactId>junit-platform-launcher</artifactId>
- <version>1.6.2</version>
+ <version>1.10.0</version>
<scope>provided</scope>
<optional>true</optional>
</dependency>
diff --git
a/src/main/java/org/apache/sling/junit/impl/servlet/JsonRenderer.java
b/src/main/java/org/apache/sling/junit/impl/servlet/JsonRenderer.java
index 1324bf3..28ec568 100644
--- a/src/main/java/org/apache/sling/junit/impl/servlet/JsonRenderer.java
+++ b/src/main/java/org/apache/sling/junit/impl/servlet/JsonRenderer.java
@@ -21,9 +21,9 @@ import java.io.UnsupportedEncodingException;
import java.util.Collection;
import java.util.Map;
-import javax.json.Json;
-import javax.json.JsonException;
-import javax.json.stream.JsonGenerator;
+import jakarta.json.Json;
+import jakarta.json.JsonException;
+import jakarta.json.stream.JsonGenerator;
import javax.servlet.http.HttpServletResponse;
import org.apache.sling.junit.Renderer;