Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolve Pitest Issues - CustomImportOrderCheck (1) #7802

Closed
rnveach opened this issue Mar 8, 2020 · 5 comments
Closed

Resolve Pitest Issues - CustomImportOrderCheck (1) #7802

rnveach opened this issue Mar 8, 2020 · 5 comments

Comments

@rnveach
Copy link
Member

rnveach commented Mar 8, 2020

Child issue of #7797 ,

"CustomImportOrderCheck.java.html:<td class='covered'><pre><span class='survived'> &#38;&#38; matcher.start() &#60; betterMatchCandidate.matchPosition) {</span></pre></td></tr>"

@wltan
Copy link
Contributor

wltan commented Mar 10, 2020

I am on it

wltan added a commit to wltan/checkstyle that referenced this issue Mar 11, 2020
@wltan
Copy link
Contributor

wltan commented Mar 11, 2020

@wltan
Copy link
Contributor

wltan commented Mar 11, 2020

Regression raised no discrepancies at all. However, I may have found the cause of the surviving mutation.

We already have unit tests in CustomImportOrderCheckTest.java that covers the different cases of regex matching, but the problem is that the input file is currently designed such that even if the test were to "fail" with the mutation, the output (violations) does not change, and so the tests incorrectly pass.

@rnveach
Copy link
Member Author

rnveach commented Mar 11, 2020

Pitest report looks good.

Hardcoded report looks good.

Regression report looks done correctly. This is a complex check with a lot of properties. If regression didn't help in this case, I would be looking to see if I turned on/off all the right options. Since a PR is started with a test case this probably isn't necessary.

See #7801 (comment) on brief discussion what would happen if no case could be created.

wltan added a commit to wltan/checkstyle that referenced this issue Mar 12, 2020
wltan added a commit to wltan/checkstyle that referenced this issue Mar 12, 2020
wltan added a commit to wltan/checkstyle that referenced this issue Mar 12, 2020
wltan added a commit to wltan/checkstyle that referenced this issue Mar 12, 2020
@rnveach
Copy link
Member Author

rnveach commented Mar 12, 2020

Fix was merged

@rnveach rnveach closed this as completed Mar 12, 2020
@rnveach rnveach added this to the 8.31 milestone Mar 12, 2020
Abhishek-kumar09 pushed a commit to Abhishek-kumar09/checkstyle that referenced this issue Mar 13, 2020
Abhishek-kumar09 pushed a commit to Abhishek-kumar09/checkstyle that referenced this issue Mar 13, 2020
ImmortalRabbit pushed a commit to ImmortalRabbit/checkstyle that referenced this issue Apr 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants