3.0.ipv8.test.test_community
Classes
Module Contents
- class 3.0.ipv8.test.test_community.OldCommunity(settings: CommunitySettings)
Bases:
3.0.ipv8.community.CommunityOld-style community that does not support new-style introduction requests.
- community_id
- create_introduction_request(socket_address: 3.0.ipv8.types.Address, extra_bytes: bytes = b'', new_style: bool = False, prefix: bytes | None = None) bytes
Make sure all sent introduction requests are flagged as old style.
- create_introduction_response(lan_socket_address: 3.0.ipv8.types.Address, socket_address: 3.0.ipv8.types.Address, identifier: int, introduction: 3.0.ipv8.peer.Peer | None = None, extra_bytes: bytes = b'', prefix: bytes | None = None, new_style: bool = False) bytes
Make sure all sent introduction responses are flagged as old style.
- class 3.0.ipv8.test.test_community.NewCommunity(settings: CommunitySettings)
Bases:
3.0.ipv8.community.CommunityA new-style supporting community.
- community_id
- class 3.0.ipv8.test.test_community.TestCommunityCompatibility
Bases:
3.0.ipv8.test.base.TestBaseTests for interoperability between old-style and new-style IPv8 Communities.
- endpoint_listener(i: int) 3.0.ipv8.test.mocking.endpoint.MockEndpointListener
Shortcut to the endpoint listener of node i.
- class 3.0.ipv8.test.test_community.NoIDCommunity(settings: CommunitySettings)
Bases:
3.0.ipv8.community.CommunityFaulty community that has no id specified.
- class 3.0.ipv8.test.test_community.StrangeIDCommunity(settings: CommunitySettings)
Bases:
3.0.ipv8.community.CommunityFaulty community that has a wrong community id type.
- community_id
- class 3.0.ipv8.test.test_community.TestCommunityInit
Bases:
3.0.ipv8.test.base.TestBaseTests for initializing new Communities.
A test for a Community with a valid id is omitted as this is already covered by other tests.
- class 3.0.ipv8.test.test_community.TestCommunityBootstrapping
Bases:
3.0.ipv8.test.base.TestBaseTests for the Community to Bootstrapper interface.
Note: don’t put tests for the Bootstrapper implementations here.