From 010a0a1f3f9929e8a362c6322bff4597bad964cb Mon Sep 17 00:00:00 2001 From: Felix Edel Date: Fri, 5 Jan 2024 15:29:10 +0100 Subject: [PATCH] Fix Elasticsearch tests The newer version of the elasticsearch library changed the underlying API, which makes our test cases fail. Adapt them accordingly. --- tests/test_elasticsearch.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/test_elasticsearch.py b/tests/test_elasticsearch.py index d53d34d..1d255e0 100644 --- a/tests/test_elasticsearch.py +++ b/tests/test_elasticsearch.py @@ -196,7 +196,7 @@ def test_elasticsearch_write(elmock): zt.save() assert elmock.return_value.index.call_args == mock.call( - index="zuul-tenants", body=zt.to_dict() + index="zuul-tenants", document=zt.to_dict() ) @@ -207,5 +207,5 @@ def test_elasticsearch_write_with_prefix(elmock): zt.save() assert elmock.return_value.index.call_args == mock.call( - index="zubbi-zuul-tenants", body=zt.to_dict() + index="zubbi-zuul-tenants", document=zt.to_dict() )