Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@schalkms
Copy link
Member

This PR reduces the complexity in both FindingsReport classes and adds some tests to the corresponding Spek classes.
There's still some code duplication there, which I'll tackle in a subsequent PR.

* Rules can classified into different severity grades. Maintainer can choose
* a grade which is most harmful to their projects.
*/
enum class Severity {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Moved this enum class into a separate .kt file.

* Debt describes the estimated amount of work needed to fix a given issue.
*/
@Suppress("MagicNumber")
data class Debt(val days: Int = 0, val hours: Int = 0, val mins: Int = 0) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Moved this data class into a separate .kt file.

@codecov-io
Copy link

codecov-io commented Jan 11, 2020

Codecov Report

Merging #2246 into master will decrease coverage by 0.02%.
The diff coverage is 89.74%.

Impacted file tree graph

@@             Coverage Diff             @@
##             master   #2246      +/-   ##
===========================================
- Coverage     81.42%   81.4%   -0.03%     
- Complexity     2081    2085       +4     
===========================================
  Files           345     346       +1     
  Lines          5993    5975      -18     
  Branches       1086    1082       -4     
===========================================
- Hits           4880    4864      -16     
- Misses          532     533       +1     
+ Partials        581     578       -3
Impacted Files Coverage Δ Complexity Δ
...in/kotlin/io/gitlab/arturbosch/detekt/api/Issue.kt 85.71% <ø> (-3.76%) 5 <0> (ø)
...itlab/arturbosch/detekt/cli/console/DebtSumming.kt 100% <100%> (+10%) 6 <2> (-1) ⬇️
...ab/arturbosch/detekt/cli/console/FindingsReport.kt 88% <81.81%> (-6.12%) 7 <0> (ø)
...osch/detekt/cli/console/FileBasedFindingsReport.kt 89.28% <90%> (-3.31%) 7 <0> (-1)
...ain/kotlin/io/gitlab/arturbosch/detekt/api/Debt.kt 93.33% <93.33%> (ø) 6 <6> (?)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 79d77fe...1afa8b6. Read the comment docs.

@arturbosch arturbosch added this to the 1.4.0 milestone Jan 12, 2020
@arturbosch arturbosch merged commit 6155569 into detekt:master Jan 12, 2020
@schalkms schalkms deleted the FindingsReport branch January 12, 2020 19:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants