diff options
author | 2024-02-12 16:22:05 +0000 | |
---|---|---|
committer | 2024-02-12 16:22:05 +0000 | |
commit | 29f622d107e65f69f12cf10d9bd7554136d653d5 (patch) | |
tree | 6156351f1c7f644139a1405af14ad6e26cec71fa | |
parent | c7858862b7ef5a5559ad4186d785a1dade39ce15 (diff) |
Replace array for collection
Without transpiling the code to typescript, it is no longer necessary to keep the values as array. instead we can use Collection/List and avoid a lot of conversion
Bug: 311642700
Test: atest FlickerTests WMShellFlickerTests
Change-Id: I43aaf5c793b97bb5b4e8568df99ed4a272e5b07b
3 files changed, 0 insertions, 3 deletions
diff --git a/libs/WindowManager/Shell/tests/flicker/splitscreen/src/com/android/wm/shell/flicker/splitscreen/UnlockKeyguardToSplitScreen.kt b/libs/WindowManager/Shell/tests/flicker/splitscreen/src/com/android/wm/shell/flicker/splitscreen/UnlockKeyguardToSplitScreen.kt index f3145c97a6f1..e6a2022166ea 100644 --- a/libs/WindowManager/Shell/tests/flicker/splitscreen/src/com/android/wm/shell/flicker/splitscreen/UnlockKeyguardToSplitScreen.kt +++ b/libs/WindowManager/Shell/tests/flicker/splitscreen/src/com/android/wm/shell/flicker/splitscreen/UnlockKeyguardToSplitScreen.kt @@ -113,7 +113,6 @@ class UnlockKeyguardToSplitScreen(override val flicker: LegacyFlickerTest) : subject.name.contains(primaryApp.toLayerName()) && subject.isVisible } .mapNotNull { primaryApp -> primaryApp.layer.visibleRegion } - .toTypedArray() val primaryAppRegionArea = RegionSubject(primaryAppRegions, it.timestamp) it.visibleRegion(secondaryApp).notOverlaps(primaryAppRegionArea.region) diff --git a/tests/FlickerTests/IME/src/com/android/server/wm/flicker/ime/CloseImeOnDismissPopupDialogTest.kt b/tests/FlickerTests/IME/src/com/android/server/wm/flicker/ime/CloseImeOnDismissPopupDialogTest.kt index 47a1619e0e9c..99e8ef5e4c3d 100644 --- a/tests/FlickerTests/IME/src/com/android/server/wm/flicker/ime/CloseImeOnDismissPopupDialogTest.kt +++ b/tests/FlickerTests/IME/src/com/android/server/wm/flicker/ime/CloseImeOnDismissPopupDialogTest.kt @@ -85,7 +85,6 @@ class CloseImeOnDismissPopupDialogTest(flicker: LegacyFlickerTest) : BaseTest(fl val visibleAreas = imeSnapshotLayers .mapNotNull { imeSnapshotLayer -> imeSnapshotLayer.layer.visibleRegion } - .toTypedArray() val imeVisibleRegion = RegionSubject(visibleAreas, timestamp) val appVisibleRegion = it.visibleRegion(imeTestApp) if (imeVisibleRegion.region.isNotEmpty) { diff --git a/tests/FlickerTests/src/com/android/server/wm/flicker/CommonAssertions.kt b/tests/FlickerTests/src/com/android/server/wm/flicker/CommonAssertions.kt index 4032121d4211..1abb8c217603 100644 --- a/tests/FlickerTests/src/com/android/server/wm/flicker/CommonAssertions.kt +++ b/tests/FlickerTests/src/com/android/server/wm/flicker/CommonAssertions.kt @@ -281,7 +281,6 @@ fun LegacyFlickerTest.snapshotStartingWindowLayerCoversExactlyOnApp( val visibleAreas = snapshotLayers .mapNotNull { snapshotLayer -> snapshotLayer.layer.visibleRegion } - .toTypedArray() val snapshotRegion = RegionSubject(visibleAreas, it.timestamp) val appVisibleRegion = it.visibleRegion(component) // Verify the size of snapshotRegion covers appVisibleRegion exactly in animation. |