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

Projects
2 participants
@Nimfadora
Contributor

Nimfadora commented May 31, 2017

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

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Jun 14, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Jun 19, 2017

Nimfadora pushed a commit to Nimfadora/checkstyle that referenced this issue Jun 20, 2017

Nimfadora pushed a commit to Nimfadora/checkstyle that referenced this issue Jun 20, 2017

Nimfadora pushed a commit to Nimfadora/checkstyle that referenced this issue Jun 21, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Jun 21, 2017

romani added a commit that referenced this issue Jun 22, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Jun 22, 2017

ps-sp added a commit to ps-sp/checkstyle that referenced this issue Jun 22, 2017

@romani romani moved this from To Do to In Progress in Practice What You Preach Jul 4, 2017

Nimfadora pushed a commit to Nimfadora/checkstyle that referenced this issue Jul 5, 2017

Nimfadora pushed a commit to Nimfadora/checkstyle that referenced this issue Jul 5, 2017

Nimfadora pushed a commit to Nimfadora/checkstyle that referenced this issue Jul 6, 2017

Nimfadora pushed a commit to Nimfadora/checkstyle that referenced this issue Jul 6, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Jul 6, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Jul 6, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Jul 7, 2017

romani added a commit that referenced this issue Jul 7, 2017

@romani

This comment has been minimized.

Show comment
Hide comment
@romani

romani Jul 7, 2017

Member

@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.

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

This comment has been minimized.

Show comment
Hide comment
@romani

romani Jul 15, 2017

Member

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

Member

romani commented Jul 15, 2017

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

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Aug 7, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Aug 14, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Aug 19, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Aug 19, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Aug 19, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Aug 19, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Aug 20, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Aug 21, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Aug 21, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Aug 21, 2017

Nimfadora added a commit to Nimfadora/checkstyle that referenced this issue Aug 21, 2017

romani added a commit that referenced this issue Aug 22, 2017

@romani romani added this to the 8.2 milestone Aug 22, 2017

@romani

This comment has been minimized.

Show comment
Hide comment
@romani

romani Aug 22, 2017

Member

Final fix is merged

Member

romani commented Aug 22, 2017

Final fix is merged

@romani romani closed this 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