From 51bf3b8bd2991b3455e36412995d3bdfc8e7904d Mon Sep 17 00:00:00 2001 From: Christian Basler Date: Sat, 12 Dec 2015 11:05:13 +0100 Subject: [PATCH] Fixed tests --- .../ch/dissem/bitmessage/networking/NetworkHandlerTest.java | 3 +++ .../test/java/ch/dissem/bitmessage/wif/WifExporterTest.java | 1 + .../test/java/ch/dissem/bitmessage/wif/WifImporterTest.java | 1 + 3 files changed, 5 insertions(+) diff --git a/networking/src/test/java/ch/dissem/bitmessage/networking/NetworkHandlerTest.java b/networking/src/test/java/ch/dissem/bitmessage/networking/NetworkHandlerTest.java index 9fb2ea5..ccd2b67 100644 --- a/networking/src/test/java/ch/dissem/bitmessage/networking/NetworkHandlerTest.java +++ b/networking/src/test/java/ch/dissem/bitmessage/networking/NetworkHandlerTest.java @@ -21,6 +21,7 @@ import ch.dissem.bitmessage.entity.valueobject.NetworkAddress; import ch.dissem.bitmessage.ports.AddressRepository; import ch.dissem.bitmessage.ports.MessageRepository; import ch.dissem.bitmessage.ports.NetworkHandler; +import ch.dissem.bitmessage.ports.ProofOfWorkRepository; import ch.dissem.bitmessage.security.bc.BouncySecurity; import ch.dissem.bitmessage.utils.Property; import org.junit.AfterClass; @@ -54,6 +55,7 @@ public class NetworkHandlerTest { .addressRepo(Mockito.mock(AddressRepository.class)) .inventory(peerInventory) .messageRepo(Mockito.mock(MessageRepository.class)) + .powRepo(Mockito.mock(ProofOfWorkRepository.class)) .port(6001) .nodeRegistry(new TestNodeRegistry()) .networkHandler(new DefaultNetworkHandler()) @@ -68,6 +70,7 @@ public class NetworkHandlerTest { .addressRepo(Mockito.mock(AddressRepository.class)) .inventory(nodeInventory) .messageRepo(Mockito.mock(MessageRepository.class)) + .powRepo(Mockito.mock(ProofOfWorkRepository.class)) .port(6002) .nodeRegistry(new TestNodeRegistry(localhost)) .networkHandler(networkHandler) diff --git a/wif/src/test/java/ch/dissem/bitmessage/wif/WifExporterTest.java b/wif/src/test/java/ch/dissem/bitmessage/wif/WifExporterTest.java index a2ee560..3e75a15 100644 --- a/wif/src/test/java/ch/dissem/bitmessage/wif/WifExporterTest.java +++ b/wif/src/test/java/ch/dissem/bitmessage/wif/WifExporterTest.java @@ -39,6 +39,7 @@ public class WifExporterTest { .networkHandler(mock(NetworkHandler.class)) .inventory(mock(Inventory.class)) .messageRepo(mock(MessageRepository.class)) + .powRepo(mock(ProofOfWorkRepository.class)) .nodeRegistry(mock(NodeRegistry.class)) .addressRepo(repo) .build(); diff --git a/wif/src/test/java/ch/dissem/bitmessage/wif/WifImporterTest.java b/wif/src/test/java/ch/dissem/bitmessage/wif/WifImporterTest.java index 862b3e3..d889523 100644 --- a/wif/src/test/java/ch/dissem/bitmessage/wif/WifImporterTest.java +++ b/wif/src/test/java/ch/dissem/bitmessage/wif/WifImporterTest.java @@ -42,6 +42,7 @@ public class WifImporterTest { .networkHandler(mock(NetworkHandler.class)) .inventory(mock(Inventory.class)) .messageRepo(mock(MessageRepository.class)) + .powRepo(mock(ProofOfWorkRepository.class)) .nodeRegistry(mock(NodeRegistry.class)) .addressRepo(repo) .build();