summaryrefslogtreecommitdiff
path: root/app/src/androidTest/java
diff options
context:
space:
mode:
authorcyberta <cyberta@riseup.net>2023-08-07 01:56:04 +0000
committercyberta <cyberta@riseup.net>2023-08-07 01:56:04 +0000
commit609ea1e6185055d8b67bcdd8f2a029a29b15241e (patch)
treef83c41d92c317ffec2897df4b39b1212ed89ab83 /app/src/androidTest/java
parent5c8c3bcc384631edd45983b8beb066cf637695d9 (diff)
parente5895097734a91097961c753771ad2b9103dd8c2 (diff)
Merge branch 'screenshot_tests' into 'master'
fix screenshot tests See merge request leap/bitmask_android!254
Diffstat (limited to 'app/src/androidTest/java')
-rw-r--r--app/src/androidTest/java/se/leap/bitmaskclient/base/ProviderBaseTest.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/app/src/androidTest/java/se/leap/bitmaskclient/base/ProviderBaseTest.java b/app/src/androidTest/java/se/leap/bitmaskclient/base/ProviderBaseTest.java
index 26cd8699..8efc6e4b 100644
--- a/app/src/androidTest/java/se/leap/bitmaskclient/base/ProviderBaseTest.java
+++ b/app/src/androidTest/java/se/leap/bitmaskclient/base/ProviderBaseTest.java
@@ -43,6 +43,7 @@ import org.junit.runner.RunWith;
import org.junit.runners.MethodSorters;
import se.leap.bitmaskclient.R;
+import se.leap.bitmaskclient.base.utils.PreferenceHelper;
import tools.fastlane.screengrab.Screengrab;
import tools.fastlane.screengrab.UiAutomatorScreenshotStrategy;
import tools.fastlane.screengrab.locale.LocaleTestRule;
@@ -63,7 +64,7 @@ public abstract class ProviderBaseTest {
@Before
public void setup() {
Screengrab.setDefaultScreenshotStrategy(new UiAutomatorScreenshotStrategy());
- SharedPreferences preferences = getApplicationContext().getSharedPreferences(SHARED_PREFERENCES, MODE_PRIVATE);
+ SharedPreferences preferences = PreferenceHelper.getSharedPreferences(getApplicationContext());
preferences.edit().clear().commit();
Instrumentation instrumentation = InstrumentationRegistry.getInstrumentation();
device = UiDevice.getInstance(instrumentation);