mirror of
https://github.com/esphome/esphome.git
synced 2025-09-02 03:12:20 +01:00
Fix unit test warning for hypothesis deprecation (#1163)
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import pytest
|
||||
|
||||
from hypothesis import given
|
||||
from hypothesis.provisional import ip4_addr_strings
|
||||
from hypothesis.provisional import ip_addresses
|
||||
|
||||
from esphome import helpers
|
||||
|
||||
@@ -75,7 +75,7 @@ def test_is_ip_address__invalid(host):
|
||||
assert actual is False
|
||||
|
||||
|
||||
@given(value=ip4_addr_strings())
|
||||
@given(value=ip_addresses(v=4).map(str))
|
||||
def test_is_ip_address__valid(value):
|
||||
actual = helpers.is_ip_address(value)
|
||||
|
||||
|
Reference in New Issue
Block a user