Skip to content

Commit

Permalink
Issue checkstyle#13999: Resolve pitest suppression for parseTag() met…
Browse files Browse the repository at this point in the history
…hod of TagParser
  • Loading branch information
suniti0804 authored and nrmancuso committed Dec 29, 2023
1 parent 16afdef commit aa68921
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 17 deletions.
9 changes: 0 additions & 9 deletions config/pitest-suppressions/pitest-javadoc-suppressions.xml
Original file line number Diff line number Diff line change
Expand Up @@ -324,15 +324,6 @@
<lineContent>text = text.substring(column).trim();</lineContent>
</mutation>

<mutation unstable="false">
<sourceFile>TagParser.java</sourceFile>
<mutatedClass>com.puppycrawl.tools.checkstyle.checks.javadoc.TagParser</mutatedClass>
<mutatedMethod>parseTag</mutatedMethod>
<mutator>org.pitest.mutationtest.engine.gregor.mutators.RemoveConditionalMutator_EQUAL_ELSE</mutator>
<description>removed conditional - replaced equality check with false</description>
<lineContent>if (incompleteTag) {</lineContent>
</mutation>

<mutation unstable="false">
<sourceFile>TagParser.java</sourceFile>
<mutatedClass>com.puppycrawl.tools.checkstyle.checks.javadoc.TagParser</mutatedClass>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,14 +127,7 @@ private Point parseTag(String[] text, int lineNo, final int nLines, Point positi
final Point endTag = findChar(text, '>', position);
final boolean incompleteTag = endTag.getLineNo() >= nLines;
// get tag id (one word)
final String tagId;

if (incompleteTag) {
tagId = "";
}
else {
tagId = getTagId(text, position);
}
final String tagId = getTagId(text, position);
// is this closed tag
final boolean closedTag =
endTag.getLineNo() < nLines
Expand Down

0 comments on commit aa68921

Please sign in to comment.