Skip to content

Commit

Permalink
Log at debug level
Browse files Browse the repository at this point in the history
Signed-off-by: Adam Korczynski <[email protected]>
  • Loading branch information
AdamKorcz committed Dec 11, 2023
1 parent a7970c6 commit 0bf5cad
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
5 changes: 1 addition & 4 deletions checks/evaluation/ci_tests.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ func CITests(name string,
// Debug PRs that were merged without CI tests
for i := range findings {
f := &findings[i]
if f.Outcome == finding.OutcomeNegative {
if f.Outcome == finding.OutcomeNegative || f.Outcome == finding.OutcomePositive {
dl.Debug(&checker.LogMessage{
Text: f.Message,
})
Expand All @@ -59,9 +59,6 @@ func CITests(name string,
return checker.CreateRuntimeErrorResult(name, e)
}

Check warning on line 60 in checks/evaluation/ci_tests.go

View check run for this annotation

Codecov / codecov/patch

checks/evaluation/ci_tests.go#L58-L60

Added lines #L58 - L60 were not covered by tests

// Log all findings
checker.LogFindings(nonNegativeFindings(findings), dl)

reason := fmt.Sprintf("%d out of %d merged PRs checked by a CI test", totalTested, totalMerged)
return checker.CreateProportionalScoreResult(CheckCITests, reason, totalTested, totalMerged)
}
Expand Down
7 changes: 3 additions & 4 deletions checks/evaluation/ci_tests_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ func TestCITests(t *testing.T) {
},
},
result: scut.TestReturn{
Score: 10,
NumberOfInfo: 1,
Score: 10,
NumberOfDebug: 1,
},
},
{
Expand Down Expand Up @@ -74,8 +74,7 @@ func TestCITests(t *testing.T) {
},
result: scut.TestReturn{
Score: 7,
NumberOfInfo: 3,
NumberOfDebug: 1,
NumberOfDebug: 4,
},
},
{
Expand Down

0 comments on commit 0bf5cad

Please sign in to comment.