From a1af556756e516d33cd9a4245c02ff431d164dfd Mon Sep 17 00:00:00 2001 From: Paul Bonser Date: Wed, 1 Feb 2017 16:59:43 -0600 Subject: [PATCH] Zero out some fields which may vary between ES versions --- goes_test.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/goes_test.go b/goes_test.go index 1abe586..24e7a1e 100644 --- a/goes_test.go +++ b/goes_test.go @@ -540,6 +540,8 @@ func (s *GoesTestSuite) TestDelete(c *C) { Version: 2, } response.Raw = nil + response.Shards.Total = 0 + response.Shards.Successful = 0 c.Assert(response, DeepEquals, expectedResponse) response, err = conn.Delete(d, url.Values{}) @@ -616,6 +618,8 @@ func (s *GoesTestSuite) TestDeleteByQuery(c *C) { Version: 0, } response.Raw = nil + response.Shards.Total = 0 + response.Shards.Successful = 0 c.Assert(response, DeepEquals, expectedResponse) //should be 0 docs after delete by query @@ -1178,6 +1182,8 @@ func (s *GoesTestSuite) TestUpdate(c *C) { } response.Raw = nil + response.Shards.Successful = 0 + response.Shards.Total = 0 c.Assert(response, DeepEquals, expectedResponse) // Now that we have an ordinary document indexed, try updating it