@@ -141,15 +141,17 @@ def test_update_firewall_lists_no_token(connection_manager):
141141 connection_manager .token = None
142142 update_firewall_lists (connection_manager )
143143 # No changes should be made, so we check the initial state
144- assert connection_manager .conf .bypassed_ips .is_empty ()
144+ assert len (connection_manager .conf .bypassed_ips .blocked_subnets ) == 0
145+ assert len (connection_manager .conf .bypassed_ips .blocked_addresses ) == 0
145146
146147
147148def test_update_firewall_lists_serverless (connection_manager ):
148149 # Set serverless to True
149150 connection_manager .serverless = True
150151 update_firewall_lists (connection_manager )
151152 # No changes should be made, so we check the initial state
152- assert connection_manager .conf .bypassed_ips .is_empty ()
153+ assert len (connection_manager .conf .bypassed_ips .blocked_subnets ) == 0
154+ assert len (connection_manager .conf .bypassed_ips .blocked_addresses ) == 0
153155
154156
155157def test_update_firewall_lists_api_failure (connection_manager ):
@@ -161,7 +163,8 @@ def fetch_firewall_lists(self, token):
161163 connection_manager .api = FailingApi ()
162164 update_firewall_lists (connection_manager )
163165 # No changes should be made, so we check the initial state
164- assert connection_manager .conf .bypassed_ips .is_empty ()
166+ assert len (connection_manager .conf .bypassed_ips .blocked_subnets ) == 0
167+ assert len (connection_manager .conf .bypassed_ips .blocked_addresses ) == 0
165168
166169
167170def test_update_firewall_lists_exception_handling (connection_manager ):
@@ -173,4 +176,5 @@ def fetch_firewall_lists(self, token):
173176 connection_manager .api = ExceptionApi ()
174177 update_firewall_lists (connection_manager )
175178 # No changes should be made, so we check the initial state
176- assert connection_manager .conf .bypassed_ips .is_empty ()
179+ assert len (connection_manager .conf .bypassed_ips .blocked_subnets ) == 0
180+ assert len (connection_manager .conf .bypassed_ips .blocked_addresses ) == 0
0 commit comments