commit f3f1165d3637bcc3ba791c4a0ceba1c7821316c8
parent f4944870263721268967d7829f8296a88ad70c0b
Author: AndiAJ <andiaj@users.noreply.github.com>
Date: Fri, 31 Oct 2025 06:36:40 +0000
Bug 1925185 - Fix verifyDRMControlledContentPermissionSettingsTest UI test r=aaronmt
The UI test was flaky when trying to verify the page content after refreshing the page and clicking the DRM access button to verify that DRM-controlled content is allowed
This was happening because the page wasn't properly loaded before clicking the DRM access button and no message was displayed.
To fix this, I've a dded a wait for the page to be loaded before clicking the DRM access button
The UI test successfully passed 100x on Firebase ✅
Differential Revision: https://phabricator.services.mozilla.com/D270657
Diffstat:
1 file changed, 2 insertions(+), 0 deletions(-)
diff --git a/mobile/android/fenix/app/src/androidTest/java/org/mozilla/fenix/ui/SettingsSitePermissionsTest.kt b/mobile/android/fenix/app/src/androidTest/java/org/mozilla/fenix/ui/SettingsSitePermissionsTest.kt
@@ -19,6 +19,7 @@ import org.mozilla.fenix.helpers.MatcherHelper.itemWithText
import org.mozilla.fenix.helpers.TestAssetHelper.getGenericAsset
import org.mozilla.fenix.helpers.TestAssetHelper.getMutedVideoPageAsset
import org.mozilla.fenix.helpers.TestAssetHelper.getVideoPageAsset
+import org.mozilla.fenix.helpers.TestAssetHelper.waitingTimeLong
import org.mozilla.fenix.helpers.TestHelper.exitMenu
import org.mozilla.fenix.helpers.TestSetup
import org.mozilla.fenix.helpers.perf.DetectMemoryLeaksRule
@@ -466,6 +467,7 @@ class SettingsSitePermissionsTest : TestSetup() {
browserScreen {
}.openThreeDotMenu {
}.refreshPage {
+ waitForPageToLoad(pageLoadWaitingTime = waitingTimeLong)
}.clickRequestDRMControlledContentAccessButton {}
browserScreen {
verifyPageContent("DRM-controlled content allowed")