apache / apache/maven-surefire
[SUREFIRE-1327] Allow failed tests to run in new fork when using reuseForks and rerunFailingTestsCount
- Dominant language
- Java
- Stars
- 461
- Forks
- 588
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 19
Description
**[Adam Lerman](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=alerman)** opened **[SUREFIRE-1327](https://issues.apache.org/jira/browse/SUREFIRE-1327?redirect=false)** and commented
Our project has 102 modules and 1000+ test classes. We use forkCount=1C and reuseForks=false as there are a few places in our project that use static variables and setting reuseForks to true causes tests failures. I would like to be able to reuseForks as it cuts significant time (30% or so) off the build, but hunting down the broken tests becomes a problem. I propose that when using rerunFailingTestsCount the runner should spawn a new fork for failed tests to ensure the test did not fail due to a dirty fork
---
**Affects:** 2.19.1
Contributor guide
Research direction
No source files or tests are named. Start by locating the handling of rerunFailingTestsCount, reuseForks, and forkCount in the Surefire test runner, then inspect existing fork and rerun tests. Done means failed tests can rerun in a newly spawned fork when the requested options apply, with coverage for failures caused by a dirty fork.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- build-system, testing-qa
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100