Skip to content

Commit c720ca3

Browse files
committed
Allow init to fail
1 parent e233446 commit c720ca3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tests/test_pairing.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -373,7 +373,8 @@ async def test_pair_plus(self, monkeypatch: pytest.MonkeyPatch) -> None:
373373
monkeypatch.setattr(pw_requests, "NODE_TIME_OUT", 0.5)
374374
stick = pw_stick.Stick(port="test_port", cache_enabled=False)
375375
await stick.connect("test_port")
376-
await stick.initialize()
376+
with pytest.raises(pw_exceptions.StickError):
377+
await stick.initialize()
377378

378379
# Inject StickNetworkInfoRequest to trigger a pairing
379380
mock_serial.inject_message(b"0001", b"1253") # @bouwew: seq_id is not FFFC!

0 commit comments

Comments
 (0)