From 2ddee9b155e373080a819bbefbfade127dcfdd43 Mon Sep 17 00:00:00 2001 From: benoit74 Date: Fri, 17 Nov 2023 10:15:23 +0100 Subject: [PATCH] Remove dead code --- .../tests/integration/routes/workers/test_worker.py | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/dispatcher/backend/src/tests/integration/routes/workers/test_worker.py b/dispatcher/backend/src/tests/integration/routes/workers/test_worker.py index f20ff099..4767bdc6 100644 --- a/dispatcher/backend/src/tests/integration/routes/workers/test_worker.py +++ b/dispatcher/backend/src/tests/integration/routes/workers/test_worker.py @@ -212,8 +212,6 @@ def test_checkin_another_user( class TestWorkerRequestedTasks: - new_ip_address = "88.88.88.88" - def test_requested_task_worker_as_admin(self, client, access_token, worker): response = client.get( "/requested-tasks/worker", @@ -240,13 +238,6 @@ def test_requested_task_worker_as_worker(self, client, make_access_token, worker ) assert response.status_code == 200 - def custom_ip_update(self, ip_addresses: List): - self.ip_updated = True - assert TestWorkerRequestedTasks.new_ip_address in ip_addresses - - def custom_failing_ip_update(self, ip_addresses: List): - raise Exception() - @pytest.mark.parametrize( "prev_ip, new_ip, external_update_enabled, external_update_fails," " external_update_called", @@ -295,7 +286,7 @@ def test_requested_task_worker_update_ip_whitelist( # setup custom ip updater to intercept Wasabi operations updater = IpUpdaterAndChecker(should_fail=external_update_fails) - assert TestWorkerRequestedTasks.new_ip_address not in updater.ip_addresses + assert new_ip not in updater.ip_addresses ExternalIpUpdater.update = updater.ip_update constants.USES_WORKERS_IPS_WHITELIST = external_update_enabled