From f847757a9a7e4a445364888abb23530c75b43405 Mon Sep 17 00:00:00 2001 From: Shreya Malviya Date: Wed, 7 Sep 2022 18:00:08 +0530 Subject: [PATCH] UT: Rename test_control_find_server_any_exception -> test_control_find_server__no_available_relays --- monkey/tests/unit_tests/infection_monkey/test_control.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/monkey/tests/unit_tests/infection_monkey/test_control.py b/monkey/tests/unit_tests/infection_monkey/test_control.py index 2298589d6..181e38d9f 100644 --- a/monkey/tests/unit_tests/infection_monkey/test_control.py +++ b/monkey/tests/unit_tests/infection_monkey/test_control.py @@ -43,14 +43,12 @@ def test_control_set_proxies(monkeypatch, is_windows_os, expected_proxy_string): assert control_client.proxies["https"] == expected_proxy_string -def test_control_find_server_any_exception(monkeypatch, servers): +def test_control_find_server__no_available_relays(monkeypatch, servers): monkeypatch.setattr("infection_monkey.control.requests.get", MockConnectionError) cc = ControlClient(servers) - return_value = cc.find_server(servers) - - assert return_value is False + assert cc.find_server(servers) is False assert servers == []