Skip to content

Commit

Permalink
Merge pull request #27 from torusresearch/feat/update-fnd-java
Browse files Browse the repository at this point in the history
feat: update fnd java version and unit-tests
  • Loading branch information
chaitanyapotti authored Jul 9, 2024
2 parents 5007915 + c33b543 commit b089a83
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 13 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ repositories {
}

dependencies {
implementation 'org.torusresearch:fetch-node-details-java:4.1.1'
implementation 'org.torusresearch:fetch-node-details-java:5.0.0'
implementation 'org.web3j:core:4.8.8-android'
implementation 'com.google.code.gson:gson:2.9.0'
implementation 'com.squareup.okhttp3:okhttp:4.9.3'
Expand Down
4 changes: 2 additions & 2 deletions src/test/java/org/torusresearch/torusutilstest/AquaTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import org.junit.jupiter.api.Test;
import org.torusresearch.fetchnodedetails.FetchNodeDetails;
import org.torusresearch.fetchnodedetails.types.NodeDetails;
import org.torusresearch.fetchnodedetails.types.TorusNetwork;
import org.torusresearch.fetchnodedetails.types.Web3AuthNetwork;
import org.torusresearch.torusutils.TorusUtils;
import org.torusresearch.torusutils.types.RetrieveSharesResponse;
import org.torusresearch.torusutils.types.TorusCtorOptions;
Expand Down Expand Up @@ -49,7 +49,7 @@ public class AquaTest {
@BeforeAll
static void setup() throws ExecutionException, InterruptedException, IOException, NoSuchAlgorithmException, InvalidKeySpecException {
System.out.println("Setup Starting");
fetchNodeDetails = new FetchNodeDetails(TorusNetwork.AQUA);
fetchNodeDetails = new FetchNodeDetails(Web3AuthNetwork.AQUA);
TorusCtorOptions opts = new TorusCtorOptions("Custom", "YOUR_CLIENT_ID");
opts.setNetwork("aqua");
opts.setSignerHost("https://signer-polygon.tor.us/api/sign");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import org.junit.jupiter.api.Test;
import org.torusresearch.fetchnodedetails.FetchNodeDetails;
import org.torusresearch.fetchnodedetails.types.NodeDetails;
import org.torusresearch.fetchnodedetails.types.TorusNetwork;
import org.torusresearch.fetchnodedetails.types.Web3AuthNetwork;
import org.torusresearch.torusutils.TorusUtils;
import org.torusresearch.torusutils.types.RetrieveSharesResponse;
import org.torusresearch.torusutils.types.TorusCtorOptions;
Expand Down Expand Up @@ -50,7 +50,7 @@ public class CelesteTest {
@BeforeAll
static void setup() throws ExecutionException, InterruptedException, IOException, NoSuchAlgorithmException, InvalidKeySpecException {
System.out.println("Setup Startingg");
fetchNodeDetails = new FetchNodeDetails(TorusNetwork.CELESTE);
fetchNodeDetails = new FetchNodeDetails(Web3AuthNetwork.CELESTE);
TorusCtorOptions opts = new TorusCtorOptions("Custom", "YOUR_CLIENT_ID");
opts.setNetwork("celeste");
opts.setSignerHost("https://signer-polygon.tor.us/api/sign");
Expand Down
4 changes: 2 additions & 2 deletions src/test/java/org/torusresearch/torusutilstest/CyanTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import org.junit.jupiter.api.Test;
import org.torusresearch.fetchnodedetails.FetchNodeDetails;
import org.torusresearch.fetchnodedetails.types.NodeDetails;
import org.torusresearch.fetchnodedetails.types.TorusNetwork;
import org.torusresearch.fetchnodedetails.types.Web3AuthNetwork;
import org.torusresearch.torusutils.TorusUtils;
import org.torusresearch.torusutils.types.RetrieveSharesResponse;
import org.torusresearch.torusutils.types.TorusCtorOptions;
Expand Down Expand Up @@ -50,7 +50,7 @@ public class CyanTest {
@BeforeAll
static void setup() throws ExecutionException, InterruptedException, IOException, NoSuchAlgorithmException, InvalidKeySpecException {
System.out.println("Setup Starting");
fetchNodeDetails = new FetchNodeDetails(TorusNetwork.CYAN);
fetchNodeDetails = new FetchNodeDetails(Web3AuthNetwork.CYAN);
TorusCtorOptions opts = new TorusCtorOptions("Custom", "YOUR_CLIENT_ID");
opts.setNetwork("cyan");
opts.setSignerHost("https://signer-polygon.tor.us/api/sign");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import org.junit.jupiter.api.Test;
import org.torusresearch.fetchnodedetails.FetchNodeDetails;
import org.torusresearch.fetchnodedetails.types.NodeDetails;
import org.torusresearch.fetchnodedetails.types.TorusNetwork;
import org.torusresearch.fetchnodedetails.types.Web3AuthNetwork;
import org.torusresearch.torusutils.TorusUtils;
import org.torusresearch.torusutils.types.RetrieveSharesResponse;
import org.torusresearch.torusutils.types.TorusCtorOptions;
Expand Down Expand Up @@ -50,7 +50,7 @@ public class MainnetTest {
@BeforeAll
static void setup() throws IOException, NoSuchAlgorithmException, InvalidKeySpecException {
System.out.println("Setup Starting");
fetchNodeDetails = new FetchNodeDetails(TorusNetwork.MAINNET);
fetchNodeDetails = new FetchNodeDetails(Web3AuthNetwork.MAINNET);
TorusCtorOptions opts = new TorusCtorOptions("Custom", "YOUR_CLIENT_ID");
opts.setNetwork("mainnet");
torusUtils = new TorusUtils(opts);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import org.junit.jupiter.api.Test;
import org.torusresearch.fetchnodedetails.FetchNodeDetails;
import org.torusresearch.fetchnodedetails.types.NodeDetails;
import org.torusresearch.fetchnodedetails.types.TorusNetwork;
import org.torusresearch.fetchnodedetails.types.Web3AuthNetwork;
import org.torusresearch.torusutils.TorusUtils;
import org.torusresearch.torusutils.types.RetrieveSharesResponse;
import org.torusresearch.torusutils.types.TorusCtorOptions;
Expand Down Expand Up @@ -50,7 +50,7 @@ public class OneKeyTest {
@BeforeAll
static void setup() throws ExecutionException, InterruptedException, IOException, NoSuchAlgorithmException, InvalidKeySpecException {
System.out.println("Setup Starting");
fetchNodeDetails = new FetchNodeDetails(TorusNetwork.TESTNET);
fetchNodeDetails = new FetchNodeDetails(Web3AuthNetwork.TESTNET);
TorusCtorOptions opts = new TorusCtorOptions("Custom", "YOUR_CLIENT_ID");
opts.setNetwork("testnet");
opts.setEnableOneKey(true);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import org.junit.jupiter.api.Test;
import org.torusresearch.fetchnodedetails.FetchNodeDetails;
import org.torusresearch.fetchnodedetails.types.NodeDetails;
import org.torusresearch.fetchnodedetails.types.TorusNetwork;
import org.torusresearch.fetchnodedetails.types.Web3AuthNetwork;
import org.torusresearch.torusutils.TorusUtils;
import org.torusresearch.torusutils.types.RetrieveSharesResponse;
import org.torusresearch.torusutils.types.TorusCtorOptions;
Expand Down Expand Up @@ -50,7 +50,7 @@ public class TorusUtilsTest {
@BeforeAll
static void setup() throws ExecutionException, InterruptedException, IOException, NoSuchAlgorithmException, InvalidKeySpecException {
System.out.println("Setup Starting");
fetchNodeDetails = new FetchNodeDetails(TorusNetwork.TESTNET);
fetchNodeDetails = new FetchNodeDetails(Web3AuthNetwork.TESTNET);
TorusCtorOptions opts = new TorusCtorOptions("Custom", "YOUR_CLIENT_ID");
opts.setNetwork("testnet");
torusUtils = new TorusUtils(opts);
Expand Down

0 comments on commit b089a83

Please sign in to comment.