From 95bf226533721d0145eec82c844279f6ebf3df40 Mon Sep 17 00:00:00 2001 From: SataQiu <1527062125@qq.com> Date: Fri, 13 Dec 2019 14:03:44 +0800 Subject: [PATCH] fix staticcheck failures of test/e2e/manifest --- hack/.staticcheck_failures | 1 - test/e2e/manifest/manifest.go | 3 +++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/hack/.staticcheck_failures b/hack/.staticcheck_failures index 880223e95de..3c9d7203b86 100644 --- a/hack/.staticcheck_failures +++ b/hack/.staticcheck_failures @@ -66,7 +66,6 @@ test/e2e/apps test/e2e/autoscaling test/e2e/instrumentation/logging/stackdriver test/e2e/instrumentation/monitoring -test/e2e/manifest test/images/agnhost/dns test/images/agnhost/inclusterclient test/images/agnhost/net/nat diff --git a/test/e2e/manifest/manifest.go b/test/e2e/manifest/manifest.go index 691c5ef1309..b3d62923c99 100644 --- a/test/e2e/manifest/manifest.go +++ b/test/e2e/manifest/manifest.go @@ -166,6 +166,9 @@ func DaemonSetFromManifest(fileName, ns string) (*appsv1.DaemonSet, error) { func RoleFromManifest(fileName, ns string) (*rbacv1.Role, error) { var role rbacv1.Role data, err := testfiles.Read(fileName) + if err != nil { + return nil, err + } json, err := utilyaml.ToJSON(data) if err != nil {