From d454ecfbff1b91781d976d4c38fdc49593f38595 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 23 Nov 2026 13:53:37 +0100 Subject: [PATCH 1/2] tests: update health and auth tests to reflect changes in influxb 2.10 release. --- tests/test_AuthorizationApi.py | 3 ++- tests/test_health.py | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/tests/test_AuthorizationApi.py b/tests/test_AuthorizationApi.py index 036f0d60..70369deb 100644 --- a/tests/test_AuthorizationApi.py +++ b/tests/test_AuthorizationApi.py @@ -101,7 +101,7 @@ def test_createAuthorizationBucket(self): organization = self.client.organizations_api().create_organization(self.generate_name("Auth Organization")) bucket = self.client.buckets_api().create_bucket(bucket_name=self.generate_name("Auth Bucket"), retention_rules=BaseTest.retention_rule(), - org=self.organization) + org=organization) resource = PermissionResource(org_id=organization.id, type="buckets", id=bucket.id) create_bucket = Permission(action="read", resource=resource) delete_bucket = Permission(action="write", resource=resource) @@ -119,6 +119,7 @@ def test_createAuthorizationBucket(self): self.assertEqual(authorization.permissions[1].action, "write") self.delete_test_bucket(bucket) + def test_findAuthorizationsByID(self): with pytest.raises(ApiException) as e: self.authorization_api().find_authorization_by_id("020f755c3c082000") diff --git a/tests/test_health.py b/tests/test_health.py index 0c03f9e3..e4392079 100644 --- a/tests/test_health.py +++ b/tests/test_health.py @@ -16,9 +16,9 @@ def setUp(self) -> None: def test_health(self): health = self.client.health() - self.assertEqual(health.message, 'ready for queries and writes') - self.assertEqual(health.status, "pass") - self.assertEqual(health.name, "influxdb") + self.assertEqual('healthy', health.message) + self.assertEqual("pass", health.status) + self.assertEqual("influxdb", health.name) def test_health_not_running_instance(self): client_not_running = InfluxDBClient("http://localhost:8099", token="my-token", debug=True) From 707920c65275cc836397e84fd73176bf93bbaab9 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 23 Nov 2026 14:14:16 +0100 Subject: [PATCH 2/2] tests: make health test match older and newer influxdbv2 releases. --- tests/test_health.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/test_health.py b/tests/test_health.py index e4392079..9e9872a2 100644 --- a/tests/test_health.py +++ b/tests/test_health.py @@ -16,7 +16,8 @@ def setUp(self) -> None: def test_health(self): health = self.client.health() - self.assertEqual('healthy', health.message) + healthResponses = ["healthy", "ready for queries and writes"] + self.assertIn(health.message, healthResponses) self.assertEqual("pass", health.status) self.assertEqual("influxdb", health.name)