-
Notifications
You must be signed in to change notification settings - Fork 357
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1321 from hcoles/feature/report_issues
Feature/report issues
- Loading branch information
Showing
31 changed files
with
350 additions
and
70 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
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
60 changes: 60 additions & 0 deletions
60
pitest-entry/src/main/java/org/pitest/mutationtest/verify/BuildMessage.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,60 @@ | ||
package org.pitest.mutationtest.verify; | ||
|
||
import java.util.Objects; | ||
import java.util.Optional; | ||
|
||
public final class BuildMessage implements Comparable<BuildMessage> { | ||
private final String text; | ||
private final String url; | ||
private final int priority; | ||
|
||
public BuildMessage(String text, String url, int priority) { | ||
this.text = text; | ||
this.url = url; | ||
this.priority = priority; | ||
} | ||
|
||
public static BuildMessage buildMessage(String text) { | ||
return new BuildMessage(text, null, 5); | ||
} | ||
|
||
public String text() { | ||
return text; | ||
} | ||
|
||
public String url() { | ||
return url; | ||
} | ||
|
||
public int priority() { | ||
return priority; | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
return text + Optional.ofNullable(url) | ||
.map( u -> " (" + u + ")").orElse(""); | ||
} | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) { | ||
return true; | ||
} | ||
if (o == null || getClass() != o.getClass()) { | ||
return false; | ||
} | ||
BuildMessage that = (BuildMessage) o; | ||
return priority == that.priority && Objects.equals(text, that.text) && Objects.equals(url, that.url); | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(text, url, priority); | ||
} | ||
|
||
@Override | ||
public int compareTo(BuildMessage o) { | ||
return Integer.compare(this.priority, o.priority); | ||
} | ||
} |
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
23 changes: 23 additions & 0 deletions
23
pitest-entry/src/main/java/org/pitest/mutationtest/verify/BuildVerifierArguments.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,23 @@ | ||
package org.pitest.mutationtest.verify; | ||
|
||
import org.pitest.classpath.CodeSource; | ||
import org.pitest.mutationtest.config.ReportOptions; | ||
|
||
public class BuildVerifierArguments { | ||
|
||
private final CodeSource code; | ||
private final ReportOptions data; | ||
|
||
public BuildVerifierArguments(CodeSource code, ReportOptions data) { | ||
this.code = code; | ||
this.data = data; | ||
} | ||
|
||
public ReportOptions data() { | ||
return data; | ||
} | ||
|
||
public CodeSource code() { | ||
return code; | ||
} | ||
} |
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.