From fe772400d3e97c6a7c417925fea0fe7ac2b0ae8f Mon Sep 17 00:00:00 2001 From: Remi Gacogne Date: Wed, 15 Mar 2023 11:01:46 +0100 Subject: [PATCH] dnsdist: Update the backend discovery tests The output of `showServers()` has been modified, and these tests parse it to know whether a backend has been correctly upgraded. --- regression-tests.dnsdist/test_BackendDiscovery.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/regression-tests.dnsdist/test_BackendDiscovery.py b/regression-tests.dnsdist/test_BackendDiscovery.py index f8b1f14041e7..df54c74e3815 100644 --- a/regression-tests.dnsdist/test_BackendDiscovery.py +++ b/regression-tests.dnsdist/test_BackendDiscovery.py @@ -356,7 +356,7 @@ def checkBackendsUpgraded(self): if line.startswith('#') or line.startswith('All'): continue tokens = line.split() - self.assertTrue(len(tokens) == 12 or len(tokens) == 13) + self.assertTrue(len(tokens) == 13 or len(tokens) == 14) if tokens[1] == '127.0.0.1:10652': # in this particular case, the upgraded backend # does not replace the existing one and thus @@ -365,8 +365,8 @@ def checkBackendsUpgraded(self): else: self.assertEquals(tokens[2], 'UP') pool = '' - if len(tokens) == 13: - pool = tokens[12] + if len(tokens) == 14: + pool = tokens[13] backends[tokens[1]] = pool expected = {