From c9e944d9f3739c31597259f446d617df19643d52 Mon Sep 17 00:00:00 2001 From: mlabusch Date: Fri, 5 May 2017 10:44:19 +0200 Subject: [PATCH] [Fix] first try to fix the build error --- runtime/productcache.go | 2 +- runtime/productcache_test.go | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/runtime/productcache.go b/runtime/productcache.go index 52effa9..d267176 100644 --- a/runtime/productcache.go +++ b/runtime/productcache.go @@ -33,7 +33,7 @@ func ProductExists(id int64) (bool, error) { } url := fmt.Sprintf(ProductURL, id) - log.Log.WithField("url", url).Info("exists product?") + log.Log.WithField("url", url).Info("does the product exist?") res, err := http.Get(url) if err != nil { return false, err diff --git a/runtime/productcache_test.go b/runtime/productcache_test.go index 71de270..3fd3370 100644 --- a/runtime/productcache_test.go +++ b/runtime/productcache_test.go @@ -20,19 +20,19 @@ func TestProductExists(t *testing.T) { } go srv.ListenAndServe() - ok, err := ProductExists(3) + ok, err := ProductExists(6) assert.True(ok) assert.NoError(err) // test cache - ok, err = ProductExists(3) + ok, err = ProductExists(6) assert.True(ok) assert.NoError(err) productExistCache = make(map[int64]boolMicroServiceCache) ProductURL = "http://localhost:8081/api-test/product/%d/" - ok, err = ProductExists(3) + ok, err = ProductExists(6) assert.Error(err) srv.Close()