From 0b5180b6c37de62bec5fe621da8f9aca47cea1bf Mon Sep 17 00:00:00 2001 From: bysph Date: Mon, 28 Oct 2019 16:49:25 +0800 Subject: [PATCH] fix golint errors (#2737) Signed-off-by: sph --- test/upgrade/examiner/internal/readiness/readiness.go | 6 +++--- test/upgrade/examiner/internal/readiness/sc_config.go | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/test/upgrade/examiner/internal/readiness/readiness.go b/test/upgrade/examiner/internal/readiness/readiness.go index 9e1765979af..ca708a8bc0a 100644 --- a/test/upgrade/examiner/internal/readiness/readiness.go +++ b/test/upgrade/examiner/internal/readiness/readiness.go @@ -67,7 +67,7 @@ func (r *readiness) TestEnvironmentIsReady() error { func (r *readiness) assertServiceCatalogIsReady() error { klog.Info("Make sure ServiceCatalog ApiServer is up") - if err := r.assertServiceCatalogApiServerIsUp(); err != nil { + if err := r.assertServiceCatalogAPIServerIsUp(); err != nil { return errors.Wrap(err, "failed during waiting for ServiceCatalog ApiServer") } klog.Info("ServiceCatalog ApiServer is ready") @@ -81,9 +81,9 @@ func (r *readiness) assertServiceCatalogIsReady() error { return nil } -func (r *readiness) assertServiceCatalogApiServerIsUp() error { +func (r *readiness) assertServiceCatalogAPIServerIsUp() error { return wait.Poll(waitInterval, timeoutInterval, func() (done bool, err error) { - deployment, err := r.client.AppsV1beta1().Deployments(r.cfg.ServiceCatalogNamespace).Get(r.cfg.ServiceCatalogApiServerName, v1.GetOptions{}) + deployment, err := r.client.AppsV1beta1().Deployments(r.cfg.ServiceCatalogNamespace).Get(r.cfg.ServiceCatalogAPIServerName, v1.GetOptions{}) if err != nil { return false, err } diff --git a/test/upgrade/examiner/internal/readiness/sc_config.go b/test/upgrade/examiner/internal/readiness/sc_config.go index ff8b0b2a43e..8a10c131756 100644 --- a/test/upgrade/examiner/internal/readiness/sc_config.go +++ b/test/upgrade/examiner/internal/readiness/sc_config.go @@ -18,7 +18,7 @@ package readiness // ServiceCatalogConfig collects all parameters from env variables required to run upgrade tests type ServiceCatalogConfig struct { - ServiceCatalogApiServerName string `envconfig:"SC_APISERVER"` + ServiceCatalogAPIServerName string `envconfig:"SC_APISERVER"` ServiceCatalogControllerServerName string `envconfig:"SC_CONTROLLER"` ServiceCatalogNamespace string `envconfig:"SC_NAMESPACE"` TestBrokerName string `envconfig:"TB_NAME"`