From a18af39da8c12a00038c7abfa2e0063c0f3eb022 Mon Sep 17 00:00:00 2001 From: Elie CHARRA Date: Thu, 28 Jul 2022 11:56:59 +0200 Subject: [PATCH] fix: linter --- pkg/driftctl_test.go | 15 --------------- pkg/resource/resource_types.go | 2 +- 2 files changed, 1 insertion(+), 16 deletions(-) diff --git a/pkg/driftctl_test.go b/pkg/driftctl_test.go index 300d02fe..aa66be1f 100644 --- a/pkg/driftctl_test.go +++ b/pkg/driftctl_test.go @@ -4,7 +4,6 @@ import ( "encoding/json" "io/ioutil" "path" - "reflect" "strings" "testing" @@ -111,15 +110,6 @@ func runTest(t *testing.T, cases TestCases) { } } -func matchByAttributes(input, attrs map[string]interface{}) bool { - for k, v := range attrs { - if value, ok := input[k]; !ok || !reflect.DeepEqual(value, v) { - return false - } - } - return true -} - func TestDriftctlRun_BasicBehavior(t *testing.T) { cases := TestCases{ @@ -1591,8 +1581,3 @@ func TestDriftctlRun_TestResourcesNormalization(t *testing.T) { } } - -func getSchema(repo dctlresource.SchemaRepositoryInterface, resourceType string) *resource.Schema { - sch, _ := repo.GetSchema(resourceType) - return sch -} diff --git a/pkg/resource/resource_types.go b/pkg/resource/resource_types.go index 6461f84f..e0e658d1 100644 --- a/pkg/resource/resource_types.go +++ b/pkg/resource/resource_types.go @@ -260,7 +260,7 @@ func IsResourceTypeSupported(ty string) bool { func GetSupportedTypes() []string { types := make([]string, 0, len(supportedTypes)) - for k, _ := range supportedTypes { + for k := range supportedTypes { types = append(types, k) }