Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions tests/test_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,16 +100,16 @@ def test_launch_and_close_v6_only(self):
rv = r.Zeroconf(interfaces=r.InterfaceChoice.Default, ip_version=r.IPVersion.V6Only)
rv.close()

@unittest.skipIf(sys.platform != 'darwin', reason="apple_p2p only available on mac")
def test_launch_and_close_apple_p2p(self):
rv = r.Zeroconf(apple_p2p=True)
rv.close()

@unittest.skipIf(sys.platform == 'darwin', reason="apple_p2p available on mac")
def test_launch_and_close_apple_p2p(self):
@unittest.skipIf(sys.platform == 'darwin', reason="apple_p2p failure path not testable on mac")
def test_launch_and_close_apple_p2p_not_mac(self):
with pytest.raises(RuntimeError):
r.Zeroconf(apple_p2p=True)

@unittest.skipIf(sys.platform != 'darwin', reason="apple_p2p happy path only testable on mac")
def test_launch_and_close_apple_p2p_on_mac(self):
rv = r.Zeroconf(apple_p2p=True)
rv.close()

def test_handle_response(self):
def mock_incoming_msg(service_state_change: r.ServiceStateChange) -> r.DNSIncoming:
ttl = 120
Expand Down