Skip to content

Commit

Permalink
Add cognitive average
Browse files Browse the repository at this point in the history
  • Loading branch information
Luni-4 committed Nov 10, 2020
1 parent fb56bea commit 5da6e60
Show file tree
Hide file tree
Showing 3 changed files with 82 additions and 48 deletions.
10 changes: 5 additions & 5 deletions rust-code-analysis-cli/src/web/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -632,7 +632,7 @@ mod tests {
"start_line": 1,
"end_line": 4,
"metrics": {"cyclomatic": {"sum": 2.0, "average": 1.0},
"cognitive": 0.0,
"cognitive": {"sum": 0.0, "average": 0.0},
"nargs": 0.,
"nexits": 0.,
"halstead": {"bugs": 0.000_942_552_557_372_941_4,
Expand All @@ -659,7 +659,7 @@ mod tests {
"start_line": 3,
"end_line": 4,
"metrics": {"cyclomatic": {"sum": 1.0, "average": 1.0},
"cognitive": 0.0,
"cognitive": {"sum": 0.0, "average": 0.0},
"nargs": 0.,
"nexits": 0.,
"halstead": {"bugs": 0.000_942_552_557_372_941_4,
Expand Down Expand Up @@ -712,7 +712,7 @@ mod tests {
"start_line": 1,
"end_line": 2,
"metrics": {"cyclomatic": {"sum": 2.0, "average": 1.0},
"cognitive": 0.0,
"cognitive": {"sum": 0.0, "average": 0.0},
"nargs": 0.,
"nexits": 0.,
"halstead": {"bugs": 0.000_942_552_557_372_941_4,
Expand Down Expand Up @@ -761,7 +761,7 @@ mod tests {
"start_line": 1,
"end_line": 2,
"metrics": {"cyclomatic": {"sum": 2.0, "average": 1.0},
"cognitive": 0.0,
"cognitive": {"sum": 0.0, "average": 0.0},
"nargs": 0.,
"nexits": 0.,
"halstead": {"bugs": 0.000_942_552_557_372_941_4,
Expand All @@ -788,7 +788,7 @@ mod tests {
"start_line": 1,
"end_line": 2,
"metrics": {"cyclomatic": {"sum": 1.0, "average": 1.0},
"cognitive": 0.0,
"cognitive": {"sum": 0.0, "average": 0.0},
"nargs": 0.,
"nexits": 0.,
"halstead": {"bugs": 0.000_942_552_557_372_941_4,
Expand Down
Loading

0 comments on commit 5da6e60

Please sign in to comment.