mirror of
https://github.com/varun-r-mallya/py-libp2p.git
synced 2025-12-31 20:36:24 +00:00
Refactor interop tests and factories
- Add `close` and `disconnect` in `Host` - Add `close` and `close_peer` in `Network` - Change `IListener.close` to async, to await for server's closing - Add factories for security transports, and modify `HostFactory`
This commit is contained in:
@ -70,3 +70,11 @@ class INetwork(ABC):
|
||||
:param notifee: object implementing Notifee interface
|
||||
:return: true if notifee registered successfully, false otherwise
|
||||
"""
|
||||
|
||||
@abstractmethod
|
||||
async def close(self) -> None:
|
||||
pass
|
||||
|
||||
@abstractmethod
|
||||
async def close_peer(self, peer_id: ID) -> None:
|
||||
pass
|
||||
|
||||
Reference in New Issue
Block a user