@@ -59,7 +59,7 @@ def test_dhcp_setup_default(self, mocker, mock_wiznet5k, mac_address):
59
59
assert dhcp_client .gateway_ip == wiz_dhcp ._UNASSIGNED_IP_ADDR
60
60
assert dhcp_client .subnet_mask == wiz_dhcp ._UNASSIGNED_IP_ADDR
61
61
assert dhcp_client .dns_server_ip == wiz_dhcp ._UNASSIGNED_IP_ADDR
62
- assert dhcp_client ._lease_time == 0
62
+ assert dhcp_client ._lease == 0
63
63
assert dhcp_client ._t1 == 0
64
64
assert dhcp_client ._t2 == 0
65
65
mac_string = "" .join ("{:02X}" .format (o ) for o in mac_address )
@@ -293,7 +293,7 @@ def test_parse_good_data(
293
293
assert dhcp_client .dhcp_server_ip == dhcp_ip
294
294
assert dhcp_client .gateway_ip == gate_ip
295
295
assert dhcp_client .dns_server_ip == dns_ip
296
- assert dhcp_client ._lease_time == lease
296
+ assert dhcp_client ._lease == lease
297
297
assert dhcp_client ._t1 == t1
298
298
assert dhcp_client ._t2 == t2
299
299
@@ -775,7 +775,7 @@ def test_called_from_requesting_with_ack(self, mock_dhcp, lease_time):
775
775
# Setup with the required state.
776
776
mock_dhcp ._dhcp_state = wiz_dhcp ._STATE_REQUESTING
777
777
# Set the lease_time (zero forces a default to be used).
778
- mock_dhcp ._lease_time = lease_time
778
+ mock_dhcp ._lease = lease_time
779
779
# Set renew to "renew" to confirm that an ACK sets it to None.
780
780
mock_dhcp ._renew = "renew"
781
781
# Set a start time.
@@ -785,7 +785,7 @@ def test_called_from_requesting_with_ack(self, mock_dhcp, lease_time):
785
785
# Confirm timers are correctly set.
786
786
assert mock_dhcp ._t1 == time .monotonic () + lease_time // 2
787
787
assert mock_dhcp ._t2 == time .monotonic () + lease_time - lease_time // 8
788
- assert mock_dhcp ._lease_time == time .monotonic () + lease_time
788
+ assert mock_dhcp ._lease == time .monotonic () + lease_time
789
789
# Check that renew is forced to None
790
790
assert mock_dhcp ._renew is None
791
791
# FSM state should be bound.
0 commit comments