From 229bcec3856e70da94f1836633b0308b77f92fb7 Mon Sep 17 00:00:00 2001 From: atyron Date: Thu, 29 Sep 2016 18:35:59 +0300 Subject: [PATCH] Fixed TestUpdate from goes_test --- goes_test.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/goes_test.go b/goes_test.go index 3c5ee86..418f197 100644 --- a/goes_test.go +++ b/goes_test.go @@ -1232,7 +1232,9 @@ func (s *GoesTestSuite) TestUpdate(c *C) { response, err = conn.Get(indexName, docType, docId, url.Values{}) c.Assert(err, Equals, nil) - c.Assert(response.Source["counter"], Equals, float64(6)) + jsonCounter, _ := response.Source["counter"].(json.Number) + counter, _ := jsonCounter.Float64() + c.Assert(counter, Equals, float64(6)) c.Assert(response.Source["user"], Equals, "foo") c.Assert(response.Source["message"], Equals, "bar")