-
Notifications
You must be signed in to change notification settings - Fork 354
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
Mutation coverage fix within lambdas #1362
Merged
Merged
Changes from 3 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
1af21b6
Mutation coverage fix within lambdas
see-quick 2abe4fc
change a bit
see-quick 726c2cf
update
see-quick 66a4bb1
Add more test cases + adjust logic to also catch overriden methods
see-quick d19cd6b
update for overloaded methods
see-quick bbb2a20
fix tests
see-quick File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The logic here is based solely on method name. If you were to add the other suggested tests they would fail as all lambdas in all the overloads of a method would be filtered if any one of the overloads was annotated.
The method signature must also be taken into account.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have updated the tests. Also, the logic should be adjusted to overridden methods. Let me know if there's something I miss...Thanks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm interesting that the build is failing after 1m but locally my build is successful without any problems.
with
mvn clean install
and
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think overrides need to be considered, just overloads within the same class. Although it is possible to navigate the class hierarchy from the bytecode, it becomes quite expensive when there are a lot of mutants.
Unhelpfully, I used the word override when I meant overload earlier when describing the test cases.
The failing test is likely because the suite runs a matrix of different java versions. Sometimes the bytecode generated differs substantially with version. Tests need to be careful what they assert on in case they are making implicit assumptions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated for overloads. Tested also with my code and it seems to work fine. Build locally is passing now I have to figure it out to fix it also upstream :D