Skip to content

Commit

Permalink
Run goimports on tagscan job tests
Browse files Browse the repository at this point in the history
This makes the linter happy.
  • Loading branch information
weyfonk committed Mar 12, 2024
1 parent 6789fb9 commit aef96a4
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions internal/cmd/controller/imagescan/tagscan_job_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,35 +6,34 @@ import (
fleet "github.com/rancher/fleet/pkg/apis/fleet.cattle.io/v1alpha1"
)


func TestLatestTag(t *testing.T) {
var alphabeticalVersions = []string{"a", "b", "c"}

tests := []struct{
tests := []struct {
name, want string
policy fleet.ImagePolicyChoice
policy fleet.ImagePolicyChoice
}{
{
name: "alphabetical asc lowercase",
policy: fleet.ImagePolicyChoice{
Alphabetical: &fleet.AlphabeticalPolicy{Order: "asc"},
},
want: "a",
},
},
{
name: "alphabetical asc uppercase",
policy: fleet.ImagePolicyChoice{
Alphabetical: &fleet.AlphabeticalPolicy{Order: "ASC"},
},
want: "a",
},
},
{
name: "alphabetical desc lowercase",
policy: fleet.ImagePolicyChoice{
Alphabetical: &fleet.AlphabeticalPolicy{Order: "desc"},
},
want: "c",
},
},
{
name: "alphabetical desc uppercase",
policy: fleet.ImagePolicyChoice{
Expand Down

0 comments on commit aef96a4

Please sign in to comment.