False error: Mutation testing requires a green suite
See original GitHub issueI am running pitest against a green suite. Though specific test classes fail when run with pitest.
The failing test classes have the following annotations:
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = "/domain-test-context.xml")
This setup is being used so that we test code against a real DB.
If I am not mistaken these annotations is the reason these classes fail when being run by pitest.
Is this solveable ?
If not then is it possible to somehow configure pitest to ignore such tests ?
Issue Analytics
- State:
- Created 9 years ago
- Comments:20 (11 by maintainers)
Top Results From Across the Web
JUnit tests pass but PIT says the suite isn't green
mutationCoverage failed : All tests did not pass without mutation when calculating line coverage. Mutation testing requires a green suite.
Read more >Error "Mutation testing requires a green suite" - Google Groups
1:mutationCoverage failed: All tests did not pass without mutation when calculating line coverage. Mutation testing requires a green suite. [ ...
Read more >Mutation Testing: Automate the Search for Imperfect Tests
Mutation testing requires a green suite. This message can occur if you have a failing test.
Read more >FAQ - PIT Mutation Testing
My tests normally run green but PIT says the suite isn't green. Most commonly this is because either : PIT is picking up...
Read more >Hunt The Bugs With Mutation Testing - Sipios
Be careful, Pitest requires that you run the mutation testing analysis again a green tests suite so you may need to run your...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I haven’t used rules for this purpose but if this is the trend, it can be supported as well. I like to do small steps to the goal and this is the first one (excluding by runners). Let’s see how it works and how people use it, then we can continue developing this option.
I heard about JUnit categories as well but if you have hundreds or thousands of tests, you don’t want to categorize them one-by-one; but yeah, this might be an option for other projects.
@StefanPenndorf I agree we should close this one. I think there may be a feature request in here to support filtering out tests that use certain junit rules, but I think that can be raised seperately if it is still something people would find useful in 2020.