-
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
CUSTOM_GETTERS_SETTERS
false positive when a property has a backing field
#1815
Conversation
### What's done: * fix
diktat-rules/src/main/kotlin/com/saveourtool/diktat/ruleset/utils/AstNodeUtils.kt
Outdated
Show resolved
Hide resolved
JUnit Tests (Windows, EnricoMi/publish-unit-test-result-action@v2) 164 files ±0 164 suites ±0 6m 33s ⏱️ -55s Results for commit d4d8fea. ± Comparison against base commit b5c1a37. ♻️ This comment has been updated with latest results. |
JUnit Tests (macOS, EnricoMi/publish-unit-test-result-action@v2) 164 files ±0 164 suites ±0 9m 20s ⏱️ +20s Results for commit d4d8fea. ± Comparison against base commit b5c1a37. ♻️ This comment has been updated with latest results. |
...ules/src/main/kotlin/com/saveourtool/diktat/ruleset/rules/chapter6/CustomGetterSetterRule.kt
Show resolved
Hide resolved
...ules/src/main/kotlin/com/saveourtool/diktat/ruleset/rules/chapter6/CustomGetterSetterRule.kt
Outdated
Show resolved
Hide resolved
...ules/src/main/kotlin/com/saveourtool/diktat/ruleset/rules/chapter6/CustomGetterSetterRule.kt
Outdated
Show resolved
Hide resolved
…ield. - added `ASTNode.isPrivate()`, `ASTNode.hasSetterGetter()` methods - added `isPairPropertyBackingField(propertyNode: ASTNode?, backingFieldNode: ASTNode?)` function - added warning tests. Closes #1709
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #1815 +/- ##
============================================
+ Coverage 78.62% 78.64% +0.02%
+ Complexity 2441 2432 -9
============================================
Files 126 126
Lines 8555 8562 +7
Branches 2163 2171 +8
============================================
+ Hits 6726 6734 +8
- Misses 861 862 +1
+ Partials 968 966 -2 ☔ View full report in Codecov by Sentry. |
What's done:
CUSTOM_GETTERS_SETTERS
on properties with backing field.Closes #1709