[
https://issues.apache.org/jira/browse/SLING-12131?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17784238#comment-17784238
]
Julian Sedding commented on SLING-12131:
----------------------------------------
We have {{org.apache.sling.testing.osgi-mock}} and
{{org.apache.sling.testing.osgi-mock}} testing libraries, which each provide a
rule. You can find projects importing them with a [github
search|https://github.com/search?q=org%3Aapache+org.apache.sling.testing.osgi-mock+language%3A%22Maven+POM%22+-repo%3Aapache%2Fsling-whiteboard&type=code]
(adjust for sling-mock). Note, when JUnit5 came along, their respective junit4
(and thus rule-based) variants were renamed to
{{org.apache.sling.testing.osgi-mock.junit4}} and
{{{}org.apache.sling.testing.sling-mock.junit4{}}}.
There's also
[{{org.apache.sling.junit.teleporter}}|https://github.com/apache/sling-org-apache-sling-junit-teleporter],
not sure that's widely used, but it would be very difficult to rewrite for
JUnit5. You could search for usages of that one as well.
> Update sling-parent pom.xml to include JUnit5 dependencies
> ----------------------------------------------------------
>
> Key: SLING-12131
> URL: https://issues.apache.org/jira/browse/SLING-12131
> Project: Sling
> Issue Type: Task
> Reporter: Rob McDougall
> Priority: Major
>
> JUnit4 is in maintenance mode (no updates in the last 2 years and then only
> security fixes). I think updating projects to JUnit5 should be encouraged.
> I am thinking this should be a relatively easy change of adding the
> junit-jupiter and junit-vintage-engine into the Dependency Management section
> of the sling-parent.
> Once this is done, individual projects could switch to the vintage-engine (at
> the very least) or move to jupiter by switching the dependency in their
> project pom.
> Some day down the road, the JUnit 4 dependencies could be removed. Projects
> that have not updated to JUnit5 (vintage or jupiter) by that time are likely
> no longer maintained.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)