summaryrefslogtreecommitdiff
path: root/app/src/main/java/se
diff options
context:
space:
mode:
authorcyBerta <cyberta@riseup.net>2019-10-19 02:24:39 +0200
committercyBerta <cyberta@riseup.net>2019-10-19 02:24:39 +0200
commitb715aeba40bfb62de2f6a158609dfd81126da25a (patch)
treecd8483054f18b532c37cf60b22289b5cecf930e2 /app/src/main/java/se
parent313627f7e8e174fab3df063905445af370deb26e (diff)
unit tests for gateway manager's gateway selection
Diffstat (limited to 'app/src/main/java/se')
-rw-r--r--app/src/main/java/se/leap/bitmaskclient/eip/VpnConfigGenerator.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/app/src/main/java/se/leap/bitmaskclient/eip/VpnConfigGenerator.java b/app/src/main/java/se/leap/bitmaskclient/eip/VpnConfigGenerator.java
index a62daca1..075aac71 100644
--- a/app/src/main/java/se/leap/bitmaskclient/eip/VpnConfigGenerator.java
+++ b/app/src/main/java/se/leap/bitmaskclient/eip/VpnConfigGenerator.java
@@ -16,6 +16,8 @@
*/
package se.leap.bitmaskclient.eip;
+import android.support.annotation.VisibleForTesting;
+
import org.json.JSONArray;
import org.json.JSONException;
import org.json.JSONObject;
@@ -111,7 +113,8 @@ public class VpnConfigGenerator {
+ secretsConfiguration();
}
- private VpnProfile createProfile(Connection.TransportType transportType) throws IOException, ConfigParser.ConfigParseError, JSONException {
+ @VisibleForTesting
+ protected VpnProfile createProfile(Connection.TransportType transportType) throws IOException, ConfigParser.ConfigParseError, JSONException {
String configuration = getConfigurationString(transportType);
ConfigParser icsOpenvpnConfigParser = new ConfigParser();
icsOpenvpnConfigParser.parseConfig(new StringReader(configuration));