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

pitest: increase mutation coverage for pitest-checkstyle-tree-walker profile to 100% #4398

Closed
Nimfadora opened this issue May 31, 2017 · 3 comments

Comments

@Nimfadora
Copy link
Contributor

We created pitest profiles for non-checks code in #4367. Currently, we should increase coverage for pitest-checkstyle-tree-walker profile up to 100%.
This issue is a subtask of #3708

Current threshold of pitest-checkstyle-tree-walker profile: 83

@romani
Copy link
Member

romani commented Jul 7, 2017

@Nimfadora ,

TreeWalker.java//lexer.setFilename(contents.getFileName());

lexer/parser is using getFilename when error in parsing is happening, try to feed parser with bad source file from lexer and syntax perspective to cover both cases.

TreeWalker.java//lexer.setTreatAssertAsKeyword(true);
lexer.setTreatEnumAsKeyword(true);

looks like you need to feed a java file with "enum" and "assert" , as I see from his code Lexer do special processing of them in its code.

ordinaryChecksResources.size() + commentChecksResources.size()

try to move them inside Hashset c-tor, if still a problem, remove this line completely.

isPositionGreater

it might be related to cases where you put /**/ at all places in class , instead of all space.
Try to change in big input file all spaces to /**/ and see a coverage. If covered, minimize input file and ... . If not covered , add to suppress.

countLinesColumns

related to javadoc Checks, you need to run javadoc Checks that are based on AbstractJavadocCheck to see effect.


JavadocDetailNodeParser.java

parseJavadocAsParseTree

run javadoc files with syntax/parsing problems.

node.setChildren((DetailNode[]) new JavadocNodeImpl[parseTree.getChildCount()]);

run all javadoc Check that are based AbstractJavadocCheck to see what input file is required.

getNextSibling

run all javadoc Check that are based AbstractJavadocCheck to see what input file is required.
If no luck, suppress pitest on this method for now.

@romani
Copy link
Member

romani commented Jul 15, 2017

profile is set to 100%, but issue is not done yet as there a lot of excludedMethods .

@romani
Copy link
Member

romani commented Aug 22, 2017

Final fix is merged

@romani romani closed this as completed Aug 22, 2017
@romani romani moved this from In Progress to Done in Practice What You Preach Aug 22, 2017
ArneLimburg pushed a commit to ArneLimburg/checkstyle that referenced this issue Aug 23, 2017
ArneLimburg pushed a commit to ArneLimburg/checkstyle that referenced this issue Aug 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

No branches or pull requests

2 participants