-
Notifications
You must be signed in to change notification settings - Fork 358
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
combine history store and incremental analyser
Concentrates incremental analysis concern behind a single interface so implementations are not limited by the implementation details of the default history store. Allows more information to be stored within history.
- Loading branch information
Showing
55 changed files
with
789 additions
and
417 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
pitest-entry/src/main/java/org/pitest/classinfo/ClassHash.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package org.pitest.classinfo; | ||
|
||
import java.math.BigInteger; | ||
|
||
public interface ClassHash { | ||
|
||
ClassIdentifier getId(); | ||
|
||
ClassName getName(); | ||
|
||
BigInteger getDeepHash(); | ||
|
||
HierarchicalClassId getHierarchicalId(); | ||
|
||
} |
7 changes: 7 additions & 0 deletions
7
pitest-entry/src/main/java/org/pitest/classinfo/ClassHashSource.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
package org.pitest.classinfo; | ||
|
||
import java.util.Optional; | ||
|
||
public interface ClassHashSource { | ||
Optional<ClassHash> fetchClassHash(ClassName name); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 0 additions & 7 deletions
7
pitest-entry/src/main/java/org/pitest/classinfo/ClassInfoSource.java
This file was deleted.
Oops, something went wrong.
20 changes: 0 additions & 20 deletions
20
pitest-entry/src/main/java/org/pitest/classinfo/NameToClassInfo.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
pitest-entry/src/main/java/org/pitest/mutationtest/History.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
package org.pitest.mutationtest; | ||
|
||
import org.pitest.classinfo.ClassName; | ||
import org.pitest.classinfo.HierarchicalClassId; | ||
import org.pitest.coverage.CoverageDatabase; | ||
import org.pitest.mutationtest.engine.MutationDetails; | ||
|
||
import java.util.Collection; | ||
import java.util.List; | ||
import java.util.function.Predicate; | ||
|
||
public interface History { | ||
|
||
void initialize(); | ||
default Predicate<ClassName> limitTests() { | ||
return c -> true; | ||
} | ||
void processCoverage(CoverageDatabase coverageData); | ||
|
||
void recordClassPath(Collection<HierarchicalClassId> ids, CoverageDatabase coverageInfo); | ||
|
||
List<MutationResult> analyse(List<MutationDetails> mutationsForClasses); | ||
|
||
void recordResult(MutationResult result); | ||
|
||
void close(); | ||
|
||
} |
3 changes: 2 additions & 1 deletion
3
pitest-entry/src/main/java/org/pitest/mutationtest/HistoryFactory.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,12 @@ | ||
package org.pitest.mutationtest; | ||
|
||
import org.pitest.classpath.CodeSource; | ||
import org.pitest.mutationtest.incremental.WriterFactory; | ||
import org.pitest.plugin.ToolClasspathPlugin; | ||
|
||
import java.io.Reader; | ||
import java.util.Optional; | ||
|
||
public interface HistoryFactory extends ToolClasspathPlugin { | ||
HistoryStore makeHistory(WriterFactory output, Optional<Reader> input); | ||
History makeHistory(CodeSource code, WriterFactory output, Optional<Reader> input); | ||
} |
24 changes: 0 additions & 24 deletions
24
pitest-entry/src/main/java/org/pitest/mutationtest/HistoryStore.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.