Search in sources :

Example 1 with RemoteNodeControllerRunnable

use of neo.network.RemoteNodeControllerRunnable in project neo-java by coranos.

the class TestNetwork method test001WaitForNetwork.

/**
 * test waiting for network.
 */
@Test
public void test001WaitForNetwork() {
    final RemoteNodeData data = CONTROLLER.getNewRemoteNodeData();
    data.setConnectionPhase(NodeConnectionPhaseEnum.UNKNOWN);
    final InetSocketAddress addressAndPort = new InetSocketAddress("127.0.0.1", 0);
    data.setTcpAddressAndPort(addressAndPort);
    final RemoteNodeControllerRunnable r = new RemoteNodeControllerRunnable(CONTROLLER, data);
    r.run();
}
Also used : RemoteNodeData(neo.network.model.RemoteNodeData) InetSocketAddress(java.net.InetSocketAddress) RemoteNodeControllerRunnable(neo.network.RemoteNodeControllerRunnable) Test(org.junit.Test)

Aggregations

InetSocketAddress (java.net.InetSocketAddress)1 RemoteNodeControllerRunnable (neo.network.RemoteNodeControllerRunnable)1 RemoteNodeData (neo.network.model.RemoteNodeData)1 Test (org.junit.Test)1