diff options
Diffstat (limited to 'tests')
2 files changed, 12 insertions, 14 deletions
diff --git a/tests/functional/safetycenter/singleuser/src/android/safetycenter/functional/ui/PrivacySubpageTest.kt b/tests/functional/safetycenter/singleuser/src/android/safetycenter/functional/ui/PrivacySubpageTest.kt index 7196567e0..da1c859e5 100644 --- a/tests/functional/safetycenter/singleuser/src/android/safetycenter/functional/ui/PrivacySubpageTest.kt +++ b/tests/functional/safetycenter/singleuser/src/android/safetycenter/functional/ui/PrivacySubpageTest.kt @@ -34,7 +34,7 @@ import com.android.safetycenter.testing.SafetyCenterFlags import com.android.safetycenter.testing.SafetyCenterFlags.deviceSupportsSafetyCenter import com.android.safetycenter.testing.SafetyCenterTestConfigs import com.android.safetycenter.testing.SafetyCenterTestConfigs.Companion.PRIVACY_SOURCE_ID_1 -import com.android.safetycenter.testing.SafetyCenterTestConfigs.Companion.PRIVACY_SOURCE_ID_2 +import com.android.safetycenter.testing.SafetyCenterTestConfigs.Companion.SOURCE_ID_1 import com.android.safetycenter.testing.SafetyCenterTestHelper import com.android.safetycenter.testing.SafetySourceTestData import com.android.safetycenter.testing.UiTestHelper.MORE_ISSUES_LABEL @@ -162,7 +162,7 @@ class PrivacySubpageTest { val firstSourceData = safetySourceTestData.criticalWithIssueWithAttributionTitle val secondSourceData = safetySourceTestData.informationWithIssueWithAttributionTitle safetyCenterTestHelper.setData(PRIVACY_SOURCE_ID_1, firstSourceData) - safetyCenterTestHelper.setData(PRIVACY_SOURCE_ID_2, secondSourceData) + safetyCenterTestHelper.setData(SOURCE_ID_1, secondSourceData) val extras = Bundle() extras.putString(EXTRA_SAFETY_SOURCES_GROUP_ID, config.safetySourcesGroups.first().id) diff --git a/tests/utils/safetycenter/java/com/android/safetycenter/testing/SafetyCenterTestConfigs.kt b/tests/utils/safetycenter/java/com/android/safetycenter/testing/SafetyCenterTestConfigs.kt index 4d3a7f0fe..de4cf7094 100644 --- a/tests/utils/safetycenter/java/com/android/safetycenter/testing/SafetyCenterTestConfigs.kt +++ b/tests/utils/safetycenter/java/com/android/safetycenter/testing/SafetyCenterTestConfigs.kt @@ -262,8 +262,8 @@ class SafetyCenterTestConfigs(private val context: Context) { /** * A simple [SafetyCenterConfig] for testing the Privacy subpage. Note that this config contains - * the [PRIVACY_SOURCE_ID_1] and [PRIVACY_SOURCE_ID_2] sources that are part of the generic - * category, and the [SOURCE_ID_1] that is part of the data category. + * the [PRIVACY_SOURCE_ID_1] source that is part of the generic category, and the [SOURCE_ID_1] + * that is part of the data category. */ val privacySubpageConfig: SafetyCenterConfig @RequiresApi(Build.VERSION_CODES.UPSIDE_DOWN_CAKE) @@ -272,7 +272,6 @@ class SafetyCenterTestConfigs(private val context: Context) { .addSafetySourcesGroup( safetySourcesGroupBuilder(ANDROID_PRIVACY_SOURCES_GROUP_ID) .addSafetySource(dynamicSafetySource(PRIVACY_SOURCE_ID_1)) - .addSafetySource(dynamicSafetySource(PRIVACY_SOURCE_ID_2)) .addSafetySource(dynamicSafetySource(SOURCE_ID_1)) .build() ) @@ -280,8 +279,8 @@ class SafetyCenterTestConfigs(private val context: Context) { /** * A simple [SafetyCenterConfig] without data sources for testing the Privacy subpage. Note that - * this config contains only [PRIVACY_SOURCE_ID_1] and [PRIVACY_SOURCE_ID_2] sources that are - * part of the generic category. Hence it doesn't have any data category sources. + * this config contains only [PRIVACY_SOURCE_ID_1] source that is part of the generic category. + * Hence it doesn't have any data category sources. */ val privacySubpageWithoutDataSourcesConfig: SafetyCenterConfig @RequiresApi(Build.VERSION_CODES.UPSIDE_DOWN_CAKE) @@ -290,7 +289,6 @@ class SafetyCenterTestConfigs(private val context: Context) { .addSafetySourcesGroup( safetySourcesGroupBuilder(ANDROID_PRIVACY_SOURCES_GROUP_ID) .addSafetySource(dynamicSafetySource(PRIVACY_SOURCE_ID_1)) - .addSafetySource(dynamicSafetySource(PRIVACY_SOURCE_ID_2)) .build() ) .build() @@ -855,12 +853,12 @@ class SafetyCenterTestConfigs(private val context: Context) { /** ID of a source provided by [summaryTestConfig]. */ const val SOURCE_ID_7 = "test_source_id_7" - /** ID of a source provided by [privacySubpageConfig]. */ + /** + * ID of a source provided by [privacySubpageConfig] and + * [privacySubpageWithoutDataSourcesConfig]. + */ const val PRIVACY_SOURCE_ID_1 = "AndroidPermissionUsage" - /** ID of a source provided by [privacySubpageConfig]. */ - const val PRIVACY_SOURCE_ID_2 = "AndroidPrivacyAppDataSharingUpdates" - /** * ID of a [SafetySourcesGroup] provided by [multipleSourcesConfig], containing two sources * of ids [SOURCE_ID_1] and [SOURCE_ID_2]. @@ -1031,8 +1029,8 @@ class SafetyCenterTestConfigs(private val context: Context) { const val ANDROID_LOCK_SCREEN_SOURCES_GROUP_ID = "AndroidLockScreenSources" /** - * ID of a [SafetySourcesGroup] provided by [privacySubpageConfig], to replicate the privacy - * sources group. + * ID of a [SafetySourcesGroup] provided by [privacySubpageConfig] and + * [privacySubpageWithoutDataSourcesConfig], to replicate the privacy sources group. */ const val ANDROID_PRIVACY_SOURCES_GROUP_ID = "AndroidPrivacySources" } |