Search in sources :

Example 6 with BeforeAll

use of org.junit.jupiter.api.BeforeAll in project nem-library by rosklyar.

the class TransactionClientTest method init.

@BeforeAll
static void init() {
    String transactionClientConfigurationPrefix = "transactionApi";
    String accountClientConfigurationPrefix = "accountApi";
    String mosaicClientConfigurationPrefix = "mosaicApi";
    String nodeClientConfigurationPrefix = "nodeApi";
    getConfigInstance().setProperty(transactionClientConfigurationPrefix + ".ribbon.listOfServers", "153.122.112.137:7890");
    getConfigInstance().setProperty(accountClientConfigurationPrefix + ".ribbon.listOfServers", "153.122.112.137:7890");
    getConfigInstance().setProperty(mosaicClientConfigurationPrefix + ".ribbon.listOfServers", "153.122.112.137:7890");
    getConfigInstance().setProperty(nodeClientConfigurationPrefix + ".ribbon.listOfServers", "153.122.112.137:7890");
    getConfigInstance().setProperty("hystrix.command.default.execution.isolation.thread.timeoutInMilliseconds", 30000);
    DefaultNemClientFactory factory = new DefaultNemClientFactory();
    transactionClient = factory.createTransactionClient(transactionClientConfigurationPrefix, TEST, factory.createMosaicClient(mosaicClientConfigurationPrefix), factory.createAccountClient(accountClientConfigurationPrefix), factory.createNodeClient(nodeClientConfigurationPrefix));
}
Also used : DefaultNemClientFactory(com.github.rosklyar.client.DefaultNemClientFactory) BeforeAll(org.junit.jupiter.api.BeforeAll)

Example 7 with BeforeAll

use of org.junit.jupiter.api.BeforeAll in project nem2-sdk-java by nemtech.

the class E2ETest method setup.

@BeforeAll
void setup() throws ExecutionException, InterruptedException, IOException {
    transactionHttp = new TransactionHttp(this.getNodeUrl());
    account = new Account("787225aaff3d2c71f4ffa32d4f19ec4922f3cd869747f267378f81f8e3fcb12d", NetworkType.MIJIN_TEST);
    multisigAccount = new Account("5edebfdbeb32e9146d05ffd232c8af2cf9f396caf9954289daa0362d097fff3b", NetworkType.MIJIN_TEST);
    cosignatoryAccount = new Account("2a2b1f5d366a5dd5dc56c3c757cf4fe6c66e2787087692cf329d7a49a594658b", NetworkType.MIJIN_TEST);
    cosignatoryAccount2 = new Account("b8afae6f4ad13a1b8aad047b488e0738a437c7389d4ff30c359ac068910c1d59", NetworkType.MIJIN_TEST);
    listener = new Listener(this.getNodeUrl());
    listener.open().get();
}
Also used : PublicAccount(io.nem.sdk.model.account.PublicAccount) Account(io.nem.sdk.model.account.Account) BeforeAll(org.junit.jupiter.api.BeforeAll)

Example 8 with BeforeAll

use of org.junit.jupiter.api.BeforeAll in project nem2-sdk-java by nemtech.

the class ListenerTest method setup.

@BeforeAll
void setup() throws IOException {
    transactionHttp = new TransactionHttp(this.getNodeUrl());
    accountHttp = new AccountHttp(this.getNodeUrl());
    account = new Account("787225aaff3d2c71f4ffa32d4f19ec4922f3cd869747f267378f81f8e3fcb12d", NetworkType.MIJIN_TEST);
    multisigAccount = new Account("5edebfdbeb32e9146d05ffd232c8af2cf9f396caf9954289daa0362d097fff3b", NetworkType.MIJIN_TEST);
    cosignatoryAccount = new Account("2a2b1f5d366a5dd5dc56c3c757cf4fe6c66e2787087692cf329d7a49a594658b", NetworkType.MIJIN_TEST);
    cosignatoryAccount2 = new Account("b8afae6f4ad13a1b8aad047b488e0738a437c7389d4ff30c359ac068910c1d59", NetworkType.MIJIN);
}
Also used : Account(io.nem.sdk.model.account.Account) BeforeAll(org.junit.jupiter.api.BeforeAll)

Aggregations

BeforeAll (org.junit.jupiter.api.BeforeAll)8 ExecutorService (java.util.concurrent.ExecutorService)3 Account (io.nem.sdk.model.account.Account)2 DefaultNemClientFactory (com.github.rosklyar.client.DefaultNemClientFactory)1 CommandServiceImpl (com.iluwatar.cqrs.commandes.CommandServiceImpl)1 QueryServiceImpl (com.iluwatar.cqrs.queries.QueryServiceImpl)1 Analyser (io.github.vocabhunter.analysis.model.Analyser)1 EnrichedSessionState (io.github.vocabhunter.analysis.session.EnrichedSessionState)1 SessionState (io.github.vocabhunter.analysis.session.SessionState)1 SimpleAnalyser (io.github.vocabhunter.analysis.simple.SimpleAnalyser)1 PublicAccount (io.nem.sdk.model.account.PublicAccount)1 URL (java.net.URL)1 Path (java.nio.file.Path)1