diff --git a/src/test/java/bdchain/api/Test.java b/src/test/java/bdchain/api/Test.java index ba92ffa..b5bedb7 100644 --- a/src/test/java/bdchain/api/Test.java +++ b/src/test/java/bdchain/api/Test.java @@ -4,7 +4,7 @@ import bdchain.api.grpc.GetLedgersResponse; import bdchain.api.grpc.TransactionType; public class Test { - public static void main(String[] args) { + public static void main(String[] args) throws InterruptedException { final String ledger = "test"; final int block_number = 1; @@ -21,6 +21,7 @@ public class Test { tlClient .sendTransaction(ledger, TransactionType.RECORD, "0x0", "0x1", "data".getBytes()) .getHash()); + tlClient.shutdown(); AccountingChainClient acClient = new AccountingChainClient("localhost", 8013); System.out.println(acClient.blockNumber(ledger).getBlockNumber()); @@ -33,5 +34,6 @@ public class Test { acClient.getTransactionByBlockNumberAndIndex(ledger, block_number, index).toString()); System.out.println( acClient.getTransactionByBlockHashAndIndex(ledger, block_hash, index).toString()); + acClient.shutdown(); } }