From 723c4042dffb20879d719ca29d7e597ac36d7c60 Mon Sep 17 00:00:00 2001 From: Andy Scherzinger Date: Thu, 5 Nov 2020 17:31:20 +0100 Subject: [PATCH] use our screenshot function, which obeys dark/color Signed-off-by: Andy Scherzinger --- .../java/com/nextcloud/client/etm/EtmActivityTest.kt | 7 +++---- .../owncloud/android/ui/activity/UploadFilesActivityIT.kt | 3 +-- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/src/androidTest/java/com/nextcloud/client/etm/EtmActivityTest.kt b/src/androidTest/java/com/nextcloud/client/etm/EtmActivityTest.kt index a4453ac943..c6b74cc030 100644 --- a/src/androidTest/java/com/nextcloud/client/etm/EtmActivityTest.kt +++ b/src/androidTest/java/com/nextcloud/client/etm/EtmActivityTest.kt @@ -25,7 +25,6 @@ package com.nextcloud.client.etm import android.app.Activity import androidx.test.espresso.intent.rule.IntentsTestRule import androidx.test.internal.runner.junit4.statement.UiThreadStatement -import com.facebook.testing.screenshot.Screenshot import com.owncloud.android.AbstractIT import com.owncloud.android.lib.resources.status.OwnCloudVersion import com.owncloud.android.utils.ScreenshotTest @@ -55,7 +54,7 @@ class EtmActivityTest : AbstractIT() { waitForIdleSync() - Screenshot.snapActivity(sut).record() + screenshot(sut) } @Test @@ -65,7 +64,7 @@ class EtmActivityTest : AbstractIT() { UiThreadStatement.runOnUiThread { sut.vm.onPageSelected(0) } - Screenshot.snapActivity(sut).record() + screenshot(sut) } @Test @@ -75,6 +74,6 @@ class EtmActivityTest : AbstractIT() { UiThreadStatement.runOnUiThread { sut.vm.onPageSelected(1) } - Screenshot.snapActivity(sut).record() + screenshot(sut) } } diff --git a/src/androidTest/java/com/owncloud/android/ui/activity/UploadFilesActivityIT.kt b/src/androidTest/java/com/owncloud/android/ui/activity/UploadFilesActivityIT.kt index 848d05d519..f132d38349 100644 --- a/src/androidTest/java/com/owncloud/android/ui/activity/UploadFilesActivityIT.kt +++ b/src/androidTest/java/com/owncloud/android/ui/activity/UploadFilesActivityIT.kt @@ -22,7 +22,6 @@ package com.owncloud.android.ui.activity import androidx.test.espresso.intent.rule.IntentsTestRule -import com.facebook.testing.screenshot.Screenshot import com.owncloud.android.AbstractIT import org.junit.Rule import org.junit.Test @@ -36,6 +35,6 @@ class UploadFilesActivityIT : AbstractIT() { fun open() { val sut: UploadFilesActivity = activityRule.launchActivity(null) - Screenshot.snapActivity(sut).record() + screenshot(sut) } }