Executor executor = new PooledExecutor();
Node node1 = NodeStarter.createTestNode(DARKNET_PORT1, 0, "pingtest", true, Node.DEFAULT_MAX_HTL, 0, random, executor, 1000, 65536, true, false, false, false, false, false, true, 0, false, false, true, false, null);
Node node2 = NodeStarter.createTestNode(DARKNET_PORT2, 0, "pingtest", true, Node.DEFAULT_MAX_HTL, 0, random, executor, 1000, 65536, true, false, false, false, false, false, true, 0, false, false, true, false, null);
// Connect
node1.connect(node2, trust, visibility);
node2.connect(node1, trust, visibility);
// No swapping
node1.start(true);
node2.start(true);
// Ping
PeerNode pn = node1.getPeerNodes()[0];