diff --git a/pkg/health/health_test.go b/pkg/health/health_test.go index f0b9d14..6eb9dba 100644 --- a/pkg/health/health_test.go +++ b/pkg/health/health_test.go @@ -139,7 +139,14 @@ func getHealthStatus(yamlPath string, t *testing.T, overwrites map[string]string if !strings.HasPrefix(yamlPath, "./testdata/") && !strings.HasPrefix(yamlPath, "../resource_customizations") { yamlPath = "./testdata/" + yamlPath } - yamlBytes, err := os.ReadFile(yamlPath) + var yamlBytes []byte + var err error + + if strings.Contains(yamlPath, "::") { + yamlBytes, err = os.ReadFile(strings.ReplaceAll(yamlPath, "::", "/")) + } else { + yamlBytes, err = os.ReadFile(yamlPath) + } require.NoError(t, err) yamlString := string(yamlBytes) diff --git a/pkg/health/testdata/AWS::ECS::Task/failed.yaml b/pkg/health/testdata/AWS/ECS/Task/failed.yaml similarity index 100% rename from pkg/health/testdata/AWS::ECS::Task/failed.yaml rename to pkg/health/testdata/AWS/ECS/Task/failed.yaml diff --git a/pkg/health/testdata/Kubernetes::Application/degraded.yaml b/pkg/health/testdata/Kubernetes/Application/degraded.yaml similarity index 100% rename from pkg/health/testdata/Kubernetes::Application/degraded.yaml rename to pkg/health/testdata/Kubernetes/Application/degraded.yaml diff --git a/pkg/health/testdata/Kubernetes::ContainerCluster/failed.yaml b/pkg/health/testdata/Kubernetes/ContainerCluster/failed.yaml similarity index 100% rename from pkg/health/testdata/Kubernetes::ContainerCluster/failed.yaml rename to pkg/health/testdata/Kubernetes/ContainerCluster/failed.yaml