diff options
author | cyBerta <cyberta@riseup.net> | 2020-07-01 00:15:52 +0200 |
---|---|---|
committer | cyBerta <cyberta@riseup.net> | 2020-07-01 00:15:52 +0200 |
commit | 015d8f9f512b5020d380aadf4af70a89a4b3dc42 (patch) | |
tree | 02d659c33e3d62be8f5e64ac991ee55767488cdb /app/src/sharedTest/java/se.leap.bitmaskclient | |
parent | 4198c9b3bb1fee4bfcb3009ac9d80610ead13466 (diff) |
inject preshipped geoip url to provider object
Diffstat (limited to 'app/src/sharedTest/java/se.leap.bitmaskclient')
-rw-r--r-- | app/src/sharedTest/java/se.leap.bitmaskclient/testutils/TestSetupHelper.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/app/src/sharedTest/java/se.leap.bitmaskclient/testutils/TestSetupHelper.java b/app/src/sharedTest/java/se.leap.bitmaskclient/testutils/TestSetupHelper.java index c7c85f8d..69fffcb4 100644 --- a/app/src/sharedTest/java/se.leap.bitmaskclient/testutils/TestSetupHelper.java +++ b/app/src/sharedTest/java/se.leap.bitmaskclient/testutils/TestSetupHelper.java @@ -51,12 +51,14 @@ public class TestSetupHelper { public static Provider getConfiguredProvider() throws IOException, JSONException { - return getProvider(null, null, null, null, null, null); + return getProvider(null, null, null, null, null, null, null); } - public static Provider getProvider(String domain, String providerIp, String providerApiIp, String caCertFile, String providerJson, String eipServiceJson) { + public static Provider getProvider(String domain, String geoipUrl, String providerIp, String providerApiIp, String caCertFile, String providerJson, String eipServiceJson) { if (domain == null) domain = "https://riseup.net"; + if (geoipUrl == null) + geoipUrl = "https://api.black.riseup.net:9001/json"; if (providerIp == null) { providerIp = ""; } @@ -74,6 +76,7 @@ public class TestSetupHelper { try { Provider p = new Provider( domain, + geoipUrl, providerIp, providerApiIp, getInputAsString(TestSetupHelper.class.getClassLoader().getResourceAsStream(caCertFile)), |