summaryrefslogtreecommitdiffhomepage
path: root/android
diff options
context:
space:
mode:
authorAlbin <albin@mullvad.net>2022-03-30 14:24:53 +0200
committerAlbin <albin@mullvad.net>2022-04-20 18:00:45 +0200
commitc741667e1aa0e7197f8cd06646d75f6a72c3d3c2 (patch)
tree10b9d0a58022c92afbe40c1df91274ab152e974e /android
parentb93a0ba3e235c8d5e53298f30322d47c34a1e76a (diff)
downloadmullvadvpn-c741667e1aa0e7197f8cd06646d75f6a72c3d3c2.tar.xz
mullvadvpn-c741667e1aa0e7197f8cd06646d75f6a72c3d3c2.zip
Adapt e2e test to updated conncheck page
Diffstat (limited to 'android')
-rw-r--r--android/e2e/src/main/java/net/mullvad/mullvadvpn/e2e/interactor/WebViewInteractor.kt6
1 files changed, 3 insertions, 3 deletions
diff --git a/android/e2e/src/main/java/net/mullvad/mullvadvpn/e2e/interactor/WebViewInteractor.kt b/android/e2e/src/main/java/net/mullvad/mullvadvpn/e2e/interactor/WebViewInteractor.kt
index 7a251f082b..df5afc4605 100644
--- a/android/e2e/src/main/java/net/mullvad/mullvadvpn/e2e/interactor/WebViewInteractor.kt
+++ b/android/e2e/src/main/java/net/mullvad/mullvadvpn/e2e/interactor/WebViewInteractor.kt
@@ -34,9 +34,9 @@ class WebViewInteractor(
// Wait for view to expand after click.
Thread.sleep(1000)
- val wireGuardIpv4Connection = webView.findObjects(By.clazz(View::class.java))
- .first { it.text?.startsWith("WireGuard") == true }
- val wireGuardIpv4Address = wireGuardIpv4Connection.text.split("\n")[2]
+ val wireGuardIpv4ConnectionRow = webView.findObjects(By.clazz(View::class.java))
+ .first { it.text?.endsWith("(WireGuard)") == true }
+ val wireGuardIpv4Address = wireGuardIpv4ConnectionRow.text.split(" ")[0].trim()
return ConnCheckState(stateText.text == CONNECTION_CHECK_IS_CONNECTED, wireGuardIpv4Address)
}