openrewrite / openrewrite/rewrite-testing-frameworks

JUnit 4 to 5 - add recipe to migrate Suites to use Select syntax

Open
#231 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

recipe
Dominant language
Java
Stars
100
Forks
105
Avg merge
2h 25m
Merged PRs (30d)
9

Description

It looks like as of version 5.8.0 (Sept 2021), JUnit 5 has a full replacement available for the Test Suite functionality from JUnit 4:

https://stackoverflow.com/a/69168139
https://junit.org/junit5/docs/5.8.0/release-notes/
https://junit.org/junit5/docs/5.8.0/user-guide/index.html#running-tests-junit-platform-runner
https://junit.org/junit5/docs/5.8.0/user-guide/index.html#junit-platform-suite-engine

As far as I can tell, Rewrite currently has no functionality to migrate JUnit4 Suites. This seems like a good addition.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the linked JUnit 5.8.0 release notes and user guide sections on the platform runner and suite engine, then inspect existing JUnit 4 migration recipes in this repository. The work is complete when a recipe exists to migrate JUnit 4 test suites to the JUnit 5 Select syntax described in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
testing-qa
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.