3.0.ipv8.test.REST.test_isolation_endpoint ========================================== .. py:module:: 3.0.ipv8.test.REST.test_isolation_endpoint Classes ------- .. autoapisummary:: 3.0.ipv8.test.REST.test_isolation_endpoint.MockSettings 3.0.ipv8.test.REST.test_isolation_endpoint.MockTunnelCommunity 3.0.ipv8.test.REST.test_isolation_endpoint.TestIsolationEndpoint Module Contents --------------- .. py:class:: MockSettings Mock tunnel settings. .. py:attribute:: peer_flags .. py:class:: MockTunnelCommunity(settings: 3.0.ipv8.messaging.anonymization.community.TunnelSettings) Bases: :py:obj:`3.0.ipv8.messaging.anonymization.community.TunnelCommunity`, :py:obj:`3.0.ipv8.test.mocking.community.MockCommunity` Fake TunnelCommunity just for circuit management. .. py:attribute:: settings .. py:attribute:: circuits .. py:attribute:: relay_from_to .. py:attribute:: exit_sockets .. py:attribute:: bootstrappers .. py:class:: TestIsolationEndpoint(methodName: str = 'runTest') Bases: :py:obj:`3.0.ipv8.test.base.TestBase`\ [\ :py:obj:`MockTunnelCommunity`\ ] Tests for REST requests to the isolation endpoint. .. py:attribute:: FAKE_BOOTSTRAP_ADDRESS :value: ('127.0.0.1', 0) .. py:method:: setUp() -> None :async: Set up with a fake tunnel community. .. py:method:: bootstrap_addresses() -> list[3.0.ipv8.types.Address] Get the bootstrapper ip addresses. .. py:method:: test_no_ip() -> None :async: Test if requests that do not specify an IP are rejected. .. py:method:: test_no_port() -> None :async: Test if requests that do not specify a port are rejected. .. py:method:: test_no_choice() -> None :async: Test if requests that do not specify a to add either an exit node or a bootstrap server. .. py:method:: test_add_bootstrap() -> None :async: Check if bootstrap nodes are correctly added. A successfully added bootstrap node is walked to. .. py:method:: test_add_exit() -> None :async: Check if exit nodes are correctly added. A successfully added exit node is walked to.