diff options
Diffstat (limited to 'java/tests/src')
| -rw-r--r-- | java/tests/src/com/android/intentresolver/UnbundledChooserActivityTest.java | 4 | ||||
| -rw-r--r-- | java/tests/src/com/android/intentresolver/contentpreview/ContentPreviewUiTest.kt | 29 |
2 files changed, 3 insertions, 30 deletions
diff --git a/java/tests/src/com/android/intentresolver/UnbundledChooserActivityTest.java b/java/tests/src/com/android/intentresolver/UnbundledChooserActivityTest.java index 6744d625..088e8923 100644 --- a/java/tests/src/com/android/intentresolver/UnbundledChooserActivityTest.java +++ b/java/tests/src/com/android/intentresolver/UnbundledChooserActivityTest.java @@ -169,7 +169,6 @@ public class UnbundledChooserActivityTest { private static final List<BooleanFlag> ALL_FLAGS = Arrays.asList( - Flags.SHARESHEET_CUSTOM_ACTIONS, Flags.SHARESHEET_RESELECTION_ACTION, Flags.SHARESHEET_IMAGE_AND_TEXT_PREVIEW, Flags.SHARESHEET_SCROLLABLE_IMAGE_PREVIEW); @@ -1719,9 +1718,6 @@ public class UnbundledChooserActivityTest { } @Test - @RequireFeatureFlags( - flags = { Flags.SHARESHEET_CUSTOM_ACTIONS_NAME }, - values = { true }) public void testLaunchWithCustomAction() throws InterruptedException { List<ResolvedComponentInfo> resolvedComponentInfos = createResolvedComponentsForTest(2); setupResolverControllers(resolvedComponentInfos); diff --git a/java/tests/src/com/android/intentresolver/contentpreview/ContentPreviewUiTest.kt b/java/tests/src/com/android/intentresolver/contentpreview/ContentPreviewUiTest.kt index 2b78a262..c6a47515 100644 --- a/java/tests/src/com/android/intentresolver/contentpreview/ContentPreviewUiTest.kt +++ b/java/tests/src/com/android/intentresolver/contentpreview/ContentPreviewUiTest.kt @@ -19,15 +19,12 @@ package com.android.intentresolver.contentpreview import android.content.res.Resources import android.view.LayoutInflater import android.view.ViewGroup -import com.android.intentresolver.TestFeatureFlagRepository -import com.android.intentresolver.flags.FeatureFlagRepository -import com.android.intentresolver.flags.Flags import com.android.intentresolver.widget.ActionRow import com.google.common.truth.Truth.assertThat import org.junit.Test class ContentPreviewUiTest { - private class TestablePreview(private val flags: FeatureFlagRepository) : ContentPreviewUi() { + private class TestablePreview() : ContentPreviewUi() { override fun getType() = 0 override fun display( @@ -43,18 +40,13 @@ class ContentPreviewUiTest { system: List<ActionRow.Action>, custom: List<ActionRow.Action> ): List<ActionRow.Action> { - return createActions(system, custom, flags) + return createActions(system, custom) } } @Test fun testCreateActions() { - val featureFlagRepository = TestFeatureFlagRepository( - mapOf( - Flags.SHARESHEET_CUSTOM_ACTIONS to true - ) - ) - val preview = TestablePreview(featureFlagRepository) + val preview = TestablePreview() val system = listOf(ActionRow.Action(label="system", icon=null) {}) val custom = listOf(ActionRow.Action(label="custom", icon=null) {}) @@ -62,19 +54,4 @@ class ContentPreviewUiTest { assertThat(preview.makeActions(system, custom)).isEqualTo(custom) assertThat(preview.makeActions(system, listOf())).isEqualTo(system) } - - @Test - fun testCreateActions_flagDisabled() { - val featureFlagRepository = TestFeatureFlagRepository( - mapOf( - Flags.SHARESHEET_CUSTOM_ACTIONS to false - ) - ) - val preview = TestablePreview(featureFlagRepository) - - val system = listOf(ActionRow.Action(label="system", icon=null) {}) - val custom = listOf(ActionRow.Action(label="custom", icon=null) {}) - - assertThat(preview.makeActions(system, custom)).isEqualTo(system) - } } |