summaryrefslogtreecommitdiffstats
path: root/runtime/ci
diff options
context:
space:
mode:
authorAlex Goodman <wagoodman@users.noreply.github.com>2023-07-06 22:01:46 -0400
committerGitHub <noreply@github.com>2023-07-06 22:01:46 -0400
commitd5e8a9296882f113e3990daca5e6b16109f512b8 (patch)
tree9182ab95acf9bdd102dd2d44a80424268f2df4b7 /runtime/ci
parent42925c1b058a3187ec1bbd63b3557517e1fe04da (diff)
Rework CI validation workflow and makefile (#460)
* rework CI validation workflow and makefile * enable push * fix job names * fix license check * fix snapshot builds * fix acceptance tests * fix linting * disable pull request event * rework windows runner caching * disable release pipeline and add issue templates
Diffstat (limited to 'runtime/ci')
-rw-r--r--runtime/ci/evaluator.go11
-rw-r--r--runtime/ci/evaluator_test.go3
-rw-r--r--runtime/ci/rule.go6
3 files changed, 9 insertions, 11 deletions
diff --git a/runtime/ci/evaluator.go b/runtime/ci/evaluator.go
index f8baeec..152bb21 100644
--- a/runtime/ci/evaluator.go
+++ b/runtime/ci/evaluator.go
@@ -2,16 +2,16 @@ package ci
import (
"fmt"
- "github.com/dustin/go-humanize"
- "github.com/wagoodman/dive/dive/image"
- "github.com/wagoodman/dive/utils"
"sort"
"strconv"
"strings"
+ "github.com/dustin/go-humanize"
+ "github.com/logrusorgru/aurora"
"github.com/spf13/viper"
- "github.com/logrusorgru/aurora"
+ "github.com/wagoodman/dive/dive/image"
+ "github.com/wagoodman/dive/utils"
)
type CiEvaluator struct {
@@ -67,7 +67,6 @@ func (ci *CiEvaluator) Evaluate(analysis *image.AnalysisResult) bool {
message: "test",
}
}
-
}
if !canEvaluate {
@@ -111,7 +110,6 @@ func (ci *CiEvaluator) Evaluate(analysis *image.AnalysisResult) bool {
status: status,
message: message,
}
-
}
ci.Tally.Total = len(ci.Results)
@@ -174,7 +172,6 @@ func (ci *CiEvaluator) Report() string {
if ci.Misconfigured {
fmt.Fprintln(&sb, aurora.Red("CI Misconfigured"))
-
} else {
summary := fmt.Sprintf("Result:%s [Total:%d] [Passed:%d] [Failed:%d] [Warn:%d] [Skipped:%d]", status, ci.Tally.Total, ci.Tally.Pass, ci.Tally.Fail, ci.Tally.Warn, ci.Tally.Skip)
if ci.Pass {
diff --git a/runtime/ci/evaluator_test.go b/runtime/ci/evaluator_test.go
index d929452..c513adf 100644
--- a/runtime/ci/evaluator_test.go
+++ b/runtime/ci/evaluator_test.go
@@ -1,11 +1,12 @@
package ci
import (
- "github.com/wagoodman/dive/dive/image/docker"
"strings"
"testing"
"github.com/spf13/viper"
+
+ "github.com/wagoodman/dive/dive/image/docker"
)
func Test_Evaluator(t *testing.T) {
diff --git a/runtime/ci/rule.go b/runtime/ci/rule.go
index 60b350d..84ccede 100644
--- a/runtime/ci/rule.go
+++ b/runtime/ci/rule.go
@@ -2,13 +2,13 @@ package ci
import (
"fmt"
- "github.com/wagoodman/dive/dive/image"
"strconv"
- "github.com/spf13/viper"
-
"github.com/dustin/go-humanize"
"github.com/logrusorgru/aurora"
+ "github.com/spf13/viper"
+
+ "github.com/wagoodman/dive/dive/image"
)
const (