From e2305af3a1a790ce0969b2ae89461b346e99d978 Mon Sep 17 00:00:00 2001 From: Ken Giusti Date: Fri, 25 Oct 2024 11:26:57 -0400 Subject: [PATCH] CI: add call to stop async tool when expecting failure (#1651) --- tests/system_tests_ssl.py | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/tests/system_tests_ssl.py b/tests/system_tests_ssl.py index 605ce8d1a..d80a45ed3 100644 --- a/tests/system_tests_ssl.py +++ b/tests/system_tests_ssl.py @@ -1151,10 +1151,11 @@ def test_ssl_client_profile_update(self): 'allowed_mechs': "EXTERNAL", 'ssl_domain': ssl_domain} with self.assertRaises(AsyncTestReceiver.TestReceiverException) as exc: - AsyncTestReceiver(f"amqps://localhost:{self.listener1_port}", - source="test/addr", - container_id="FooRx2", - conn_args=conn_args) + atr = AsyncTestReceiver(f"amqps://localhost:{self.listener1_port}", + source="test/addr", + container_id="FooRx2", + conn_args=conn_args) + atr.stop() self.assertIn("certificate verify failed", str(exc.exception), f"{exc.exception}") ssl_domain = SSLDomain(SSLDomain.MODE_CLIENT) @@ -1165,10 +1166,11 @@ def test_ssl_client_profile_update(self): 'allowed_mechs': "EXTERNAL", 'ssl_domain': ssl_domain} with self.assertRaises(AsyncTestReceiver.TestReceiverException) as exc: - AsyncTestReceiver(f"amqps://localhost:{self.listener2_port}", - source="test/addr", - container_id="FooRx3", - conn_args=conn_args) + atr = AsyncTestReceiver(f"amqps://localhost:{self.listener2_port}", + source="test/addr", + container_id="FooRx3", + conn_args=conn_args) + atr.stop() self.assertIn("certificate verify failed", str(exc.exception), f"{exc.exception}") #