-
Notifications
You must be signed in to change notification settings - Fork 39
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
Collapse if statements with comments #825
Collapse if statements with comments #825
Conversation
### What's done: * Change collapseThenBlocks function: KtBlockExpression.statements didn't hold comments, now it's fixed * Monitor, which types of nodes are followed after nested if (more proper way), instead of check, that this if is the last child * Fix indentions in tests
Codecov Report
@@ Coverage Diff @@
## master #825 +/- ##
============================================
+ Coverage 80.91% 80.98% +0.07%
- Complexity 2272 2289 +17
============================================
Files 100 100
Lines 5801 5833 +32
Branches 1798 1813 +15
============================================
+ Hits 4694 4724 +30
Misses 286 286
- Partials 821 823 +2
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
### What's done: * Add logic for if statements with commets and cover it with tests
758c34f
to
84dfaf2
Compare
### What's done: * Fix codestyle warning && and more tests
08b65f8
to
8843848
Compare
diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/chapter3/CollapseIfStatementsRule.kt
Show resolved
Hide resolved
diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/chapter3/CollapseIfStatementsRule.kt
Show resolved
Hide resolved
diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/chapter3/CollapseIfStatementsRule.kt
Outdated
Show resolved
Hide resolved
diktat-rules/src/main/kotlin/org/cqfn/diktat/ruleset/rules/chapter3/CollapseIfStatementsRule.kt
Show resolved
Hide resolved
### What's done: * Add recommendations from review and add more tests
### What's done: Add comments about of absence of a KDOC in allowed types
### What's done: * Improve logic, when if-statements already have comments in conditions * Add tests
…entions rules ### What's done: * CollapseIfStatements rule should be invoked before LineLength and Indentions rules
### What's done: * Fix codestyle issues
@petertrr I improved the way of comments processing, check please last commits |
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.
LGTM
What's done: