@@ -29,15 +29,23 @@ class CleanthatJavaRefactorerTest extends MavenIntegrationHarness {
2929 void testLiteralsFirstInComparisons () throws Exception {
3030 writePomWithJavaSteps (
3131 "<cleanthat>" ,
32+ " <mutators>" ,
33+ " <mutator>LiteralsFirstInComparisons</mutator>" ,
34+ " </mutators>" ,
3235 "</cleanthat>" );
3336
3437 runTest ("LiteralsFirstInComparisons.dirty.java" , "LiteralsFirstInComparisons.clean.java" );
3538 }
3639
3740 @ Test
3841 void testMultipleMutators_defaultIsJdk7 () throws Exception {
42+ // OptionalNotEmpty will be excluded as it is not compatible with JDK7
3943 writePomWithJavaSteps (
4044 "<cleanthat>" ,
45+ " <mutators>" ,
46+ " <mutator>LiteralsFirstInComparisons</mutator>" ,
47+ " <mutator>OptionalNotEmpty</mutator>" ,
48+ " </mutators>" ,
4149 "</cleanthat>" );
4250
4351 runTest ("MultipleMutators.dirty.java" , "MultipleMutators.clean.onlyLiteralsFirst.java" );
@@ -47,7 +55,11 @@ void testMultipleMutators_defaultIsJdk7() throws Exception {
4755 void testMultipleMutators_Jdk11IntroducedOptionalisPresent () throws Exception {
4856 writePomWithJavaSteps (
4957 "<cleanthat>" ,
50- "<sourceJdk>11</sourceJdk>" ,
58+ " <sourceJdk>11</sourceJdk>" ,
59+ " <mutators>" ,
60+ " <mutator>LiteralsFirstInComparisons</mutator>" ,
61+ " <mutator>OptionalNotEmpty</mutator>" ,
62+ " </mutators>" ,
5163 "</cleanthat>" );
5264
5365 runTest ("MultipleMutators.dirty.java" , "MultipleMutators.clean.java" );
@@ -57,6 +69,10 @@ void testMultipleMutators_Jdk11IntroducedOptionalisPresent() throws Exception {
5769 void testExcludeOptionalNotEmpty () throws Exception {
5870 writePomWithJavaSteps (
5971 "<cleanthat>" ,
72+ " <mutators>" ,
73+ " <mutator>LiteralsFirstInComparisons</mutator>" ,
74+ " <mutator>OptionalNotEmpty</mutator>" ,
75+ " </mutators>" ,
6076 " <excludedMutators>" ,
6177 " <excludedMutator>OptionalNotEmpty</excludedMutator>" ,
6278 " </excludedMutators>" ,
0 commit comments