Fixed TorNetworkNode tests

This commit is contained in:
Florian Reimair 2018-12-07 09:54:10 +01:00
parent fdd6e7186c
commit f134b278ff

View File

@ -53,7 +53,7 @@ public class TorNetworkNodeTest {
public void testTorNodeBeforeSecondReady() throws InterruptedException, IOException { public void testTorNodeBeforeSecondReady() throws InterruptedException, IOException {
latch = new CountDownLatch(1); latch = new CountDownLatch(1);
int port = 9001; int port = 9001;
TorNetworkNode node1 = new TorNetworkNode(port, TestUtils.getNetworkProtoResolver(), TorNetworkNode node1 = new TorNetworkNode(port, TestUtils.getNetworkProtoResolver(), false,
new NewTor(new File("torNode_" + port), "", "", new ArrayList<String>())); new NewTor(new File("torNode_" + port), "", "", new ArrayList<String>()));
node1.start(new SetupListener() { node1.start(new SetupListener() {
@Override @Override
@ -80,7 +80,7 @@ public class TorNetworkNodeTest {
latch = new CountDownLatch(1); latch = new CountDownLatch(1);
int port2 = 9002; int port2 = 9002;
TorNetworkNode node2 = new TorNetworkNode(port2, TestUtils.getNetworkProtoResolver(), TorNetworkNode node2 = new TorNetworkNode(port2, TestUtils.getNetworkProtoResolver(), false,
new NewTor(new File("torNode_" + port), "", "", new ArrayList<String>())); new NewTor(new File("torNode_" + port), "", "", new ArrayList<String>()));
node2.start(new SetupListener() { node2.start(new SetupListener() {
@Override @Override
@ -138,7 +138,7 @@ public class TorNetworkNodeTest {
public void testTorNodeAfterBothReady() throws InterruptedException, IOException { public void testTorNodeAfterBothReady() throws InterruptedException, IOException {
latch = new CountDownLatch(2); latch = new CountDownLatch(2);
int port = 9001; int port = 9001;
TorNetworkNode node1 = new TorNetworkNode(port, TestUtils.getNetworkProtoResolver(), TorNetworkNode node1 = new TorNetworkNode(port, TestUtils.getNetworkProtoResolver(), false,
new NewTor(new File("torNode_" + port), "", "", new ArrayList<String>())); new NewTor(new File("torNode_" + port), "", "", new ArrayList<String>()));
node1.start(new SetupListener() { node1.start(new SetupListener() {
@Override @Override
@ -164,7 +164,7 @@ public class TorNetworkNodeTest {
}); });
int port2 = 9002; int port2 = 9002;
TorNetworkNode node2 = new TorNetworkNode(port2, TestUtils.getNetworkProtoResolver(), TorNetworkNode node2 = new TorNetworkNode(port2, TestUtils.getNetworkProtoResolver(), false,
new NewTor(new File("torNode_" + port), "", "", new ArrayList<String>())); new NewTor(new File("torNode_" + port), "", "", new ArrayList<String>()));
node2.start(new SetupListener() { node2.start(new SetupListener() {
@Override @Override