Fix test, add singleton check for ChargeBackRisk

This commit is contained in:
sqrrm 2019-08-27 12:47:02 +02:00
parent e3bd3a99e3
commit ace881cc04
No known key found for this signature in database
GPG Key ID: 45235F9EF87089EC
2 changed files with 7 additions and 0 deletions

View File

@ -32,6 +32,7 @@ import bisq.core.notifications.alerts.MyOfferTakenEvents;
import bisq.core.notifications.alerts.TradeEvents;
import bisq.core.notifications.alerts.market.MarketAlerts;
import bisq.core.notifications.alerts.price.PriceAlert;
import bisq.core.payment.ChargeBackRisk;
import bisq.core.payment.TradeLimits;
import bisq.core.proto.network.CoreNetworkProtoResolver;
import bisq.core.proto.persistable.CorePersistenceProtoResolver;
@ -131,6 +132,7 @@ public class GuiceSetupTest {
assertSingleton(TradeEvents.class);
assertSingleton(PriceAlert.class);
assertSingleton(MarketAlerts.class);
assertSingleton(ChargeBackRisk.class);
assertNotSingleton(Storage.class);
}

View File

@ -3,6 +3,8 @@ package bisq.seednode;
import bisq.core.app.BisqEnvironment;
import bisq.core.app.misc.AppSetupWithP2PAndDAO;
import bisq.core.app.misc.ModuleForAppWithP2p;
import bisq.core.locale.CurrencyUtil;
import bisq.core.locale.Res;
import org.springframework.mock.env.MockPropertySource;
@ -13,6 +15,9 @@ import org.junit.Test;
public class GuiceSetupTest {
@Test
public void testGuiceSetup() {
Res.setup();
CurrencyUtil.setup();
ModuleForAppWithP2p module = new ModuleForAppWithP2p(new BisqEnvironment(new MockPropertySource()));
Guice.createInjector(module).getInstance(AppSetupWithP2PAndDAO.class);
}