Skip to content

Commit 4057ba6

Browse files
committed
Merge test from aosp qpr2
Signed-off-by: Saul Henriquez <saul_henriquez@hotmail.com>
1 parent d817a1d commit 4057ba6

File tree

289 files changed

+16209
-7239
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

289 files changed

+16209
-7239
lines changed

tests/Android.bp

Lines changed: 19 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
package {
1616
// See: http://go/android-license-faq
1717
default_applicable_licenses: ["Android-Apache-2.0"],
18+
default_team: "trendy_team_launcher",
1819
}
1920

2021
// Source code used for test
@@ -25,6 +26,8 @@ filegroup {
2526
"src/**/*.kt",
2627
"multivalentTests/src/**/*.java",
2728
"multivalentTests/src/**/*.kt",
29+
"src_e2e/**/*.java",
30+
"src_e2e/**/*.kt",
2831
],
2932
exclude_srcs: [
3033
":launcher-non-quickstep-tests-src",
@@ -57,22 +60,13 @@ filegroup {
5760
name: "launcher-oop-tests-src",
5861
srcs: [
5962
":launcher-testing-helpers",
60-
"src/com/android/launcher3/allapps/TaplOpenCloseAllAppsTest.java",
61-
"src/com/android/launcher3/allapps/TaplAllAppsIconsWorkingTest.java",
62-
"src/com/android/launcher3/appiconmenu/TaplAppIconMenuTest.java",
63-
"src/com/android/launcher3/dragging/TaplDragTest.java",
64-
"src/com/android/launcher3/dragging/TaplUninstallRemoveTest.java",
65-
"src/com/android/launcher3/ui/TaplTestsLauncher3Test.java",
66-
"src/com/android/launcher3/ui/workspace/TaplWorkspaceTest.java",
63+
":launcher-oop-tests-only",
6764
],
6865
}
6966

7067
// Library with all the dependencies for building quickstep
7168
android_library {
7269
name: "Launcher3TestLib",
73-
defaults: [
74-
"launcher_compose_tests_defaults",
75-
],
7670
srcs: [],
7771
asset_dirs: ["assets"],
7872
resource_dirs: ["res"],
@@ -96,9 +90,11 @@ android_library {
9690
"testables",
9791
"com_android_launcher3_flags_lib",
9892
"com_android_wm_shell_flags_lib",
93+
"com_android_systemui_shared_flags_lib",
9994
"android.appwidget.flags-aconfig-java",
10095
"platform-parametric-runner-lib",
10196
"kotlin-reflect",
97+
"kotlin-test",
10298
],
10399
manifest: "AndroidManifest-common.xml",
104100
platform_apis: true,
@@ -126,9 +122,15 @@ android_test {
126122
":launcher-tests-src",
127123
":launcher-non-quickstep-tests-src",
128124
],
125+
exclude_srcs: [
126+
// Launcher3 tests setup has an issue with resolving a few resources within transitive
127+
// compose dependencies that work fine in actual Launcher3 app.
128+
"src_e2e/com/android/launcher3/widget/TaplAddWidgetTest.java",
129+
],
129130
static_libs: [
130131
"Launcher3TestLib",
131132
"com_android_launcher3_flags_lib",
133+
"com_android_systemui_shared_flags_lib",
132134
],
133135
libs: [
134136
"android.test.base.stubs.system",
@@ -149,6 +151,9 @@ android_test {
149151
data: [":Launcher3"],
150152
plugins: ["dagger2-compiler"],
151153
test_suites: ["general-tests"],
154+
lint: {
155+
baseline_filename: "lint-baseline.xml",
156+
},
152157
}
153158

154159
filegroup {
@@ -158,8 +163,8 @@ filegroup {
158163
"src/**/*.kt",
159164
"multivalentTests/src/**/*.java",
160165
"multivalentTests/src/**/*.kt",
161-
"src/com/android/launcher3/ui/AbstractLauncherUiTest.java",
162-
"src/com/android/launcher3/ui/BaseLauncherTaplTest.java",
166+
"src/com/android/launcher3/util/ui/AbstractLauncherUiTest.java",
167+
"src/com/android/launcher3/util/ui/BaseLauncherTaplTest.java",
163168
"tapl/com/android/launcher3/tapl/*.java",
164169
"tapl/com/android/launcher3/tapl/*.kt",
165170
],
@@ -169,6 +174,7 @@ filegroup {
169174
"src/**/*Test.kt",
170175
"src/**/RoboApiWrapper.kt",
171176
"src/**/EventsRule.kt",
177+
"src/**/LauncherCustomizer.kt",
172178
"multivalentTests/src/**/*Test.java",
173179
"multivalentTests/src/**/*Test.kt",
174180
],
@@ -201,6 +207,7 @@ android_robolectric_test {
201207
"flag-junit",
202208
"com_android_launcher3_flags_lib",
203209
"com_android_wm_shell_flags_lib",
210+
"com_android_systemui_shared_flags_lib",
204211
"androidx.test.uiautomator_uiautomator",
205212
"androidx.core_core-animation-testing",
206213
"androidx.test.ext.junit",

tests/AndroidManifest.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@
2323

2424
<application android:debuggable="true">
2525
<uses-library android:name="android.test.runner" />
26+
<activity
27+
android:name="platform.test.screenshot.ScreenshotActivity"
28+
android:exported="true" />
2629
</application>
2730

2831
<instrumentation

tests/assets/dumpTests/DeviceProfileDumpTest/phonePortrait.txt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ DeviceProfile:
55
transposeLayoutWithOrientation:true
66
isGestureMode:true
77
isLandscape:false
8-
isMultiWindowMode:false
8+
isExternalDisplay:false
99
isTwoPanels:false
1010
isLeftRightSplit:false
1111
windowX: 0.0px (0.0dp)
@@ -67,8 +67,8 @@ DeviceProfile:
6767
allAppsBorderSpacePxY: 42.0px (16.0dp)
6868
numShownAllAppsColumns: 5
6969
allAppsPadding.top: 118.0px (44.95238dp)
70-
allAppsPadding.left: 0.0px (0.0dp)
71-
allAppsPadding.right: 0.0px (0.0dp)
70+
allAppsPadding.left: 21.0px (8.0dp)
71+
allAppsPadding.right: 21.0px (8.0dp)
7272
allAppsLeftRightMargin: 0.0px (0.0dp)
7373
hotseatBarSizePx: 273.0px (104.0dp)
7474
mHotseatColumnSpan: 5
@@ -117,7 +117,6 @@ DeviceProfile:
117117
overviewActionsTopMarginPx: 0.0px (0.0dp)
118118
overviewActionsHeight: 0.0px (0.0dp)
119119
overviewActionsClaimedSpaceBelow: 63.0px (24.0dp)
120-
overviewActionsButtonSpacing: 0.0px (0.0dp)
121120
overviewPageSpacing: 0.0px (0.0dp)
122121
overviewRowSpacing: 0.0px (0.0dp)
123122
overviewGridSideMargin: 0.0px (0.0dp)

tests/assets/dumpTests/DeviceProfileDumpTest/phonePortrait3Button.txt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ DeviceProfile:
55
transposeLayoutWithOrientation:true
66
isGestureMode:false
77
isLandscape:false
8-
isMultiWindowMode:false
8+
isExternalDisplay:false
99
isTwoPanels:false
1010
isLeftRightSplit:false
1111
windowX: 0.0px (0.0dp)
@@ -67,8 +67,8 @@ DeviceProfile:
6767
allAppsBorderSpacePxY: 42.0px (16.0dp)
6868
numShownAllAppsColumns: 5
6969
allAppsPadding.top: 118.0px (44.95238dp)
70-
allAppsPadding.left: 0.0px (0.0dp)
71-
allAppsPadding.right: 0.0px (0.0dp)
70+
allAppsPadding.left: 21.0px (8.0dp)
71+
allAppsPadding.right: 21.0px (8.0dp)
7272
allAppsLeftRightMargin: 0.0px (0.0dp)
7373
hotseatBarSizePx: 294.0px (112.0dp)
7474
mHotseatColumnSpan: 5
@@ -117,7 +117,6 @@ DeviceProfile:
117117
overviewActionsTopMarginPx: 0.0px (0.0dp)
118118
overviewActionsHeight: 0.0px (0.0dp)
119119
overviewActionsClaimedSpaceBelow: 126.0px (48.0dp)
120-
overviewActionsButtonSpacing: 0.0px (0.0dp)
121120
overviewPageSpacing: 0.0px (0.0dp)
122121
overviewRowSpacing: 0.0px (0.0dp)
123122
overviewGridSideMargin: 0.0px (0.0dp)

tests/assets/dumpTests/DeviceProfileDumpTest/phoneVerticalBar.txt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ DeviceProfile:
55
transposeLayoutWithOrientation:true
66
isGestureMode:true
77
isLandscape:true
8-
isMultiWindowMode:false
8+
isExternalDisplay:false
99
isTwoPanels:false
1010
isLeftRightSplit:true
1111
windowX: 0.0px (0.0dp)
@@ -67,8 +67,8 @@ DeviceProfile:
6767
allAppsBorderSpacePxY: 42.0px (16.0dp)
6868
numShownAllAppsColumns: 5
6969
allAppsPadding.top: 74.0px (28.190475dp)
70-
allAppsPadding.left: 0.0px (0.0dp)
71-
allAppsPadding.right: 0.0px (0.0dp)
70+
allAppsPadding.left: 32.0px (12.190476dp)
71+
allAppsPadding.right: 32.0px (12.190476dp)
7272
allAppsLeftRightMargin: 0.0px (0.0dp)
7373
hotseatBarSizePx: 252.0px (96.0dp)
7474
mHotseatColumnSpan: 5
@@ -117,7 +117,6 @@ DeviceProfile:
117117
overviewActionsTopMarginPx: 0.0px (0.0dp)
118118
overviewActionsHeight: 0.0px (0.0dp)
119119
overviewActionsClaimedSpaceBelow: 63.0px (24.0dp)
120-
overviewActionsButtonSpacing: 0.0px (0.0dp)
121120
overviewPageSpacing: 0.0px (0.0dp)
122121
overviewRowSpacing: 0.0px (0.0dp)
123122
overviewGridSideMargin: 0.0px (0.0dp)

tests/assets/dumpTests/DeviceProfileDumpTest/phoneVerticalBar3Button.txt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ DeviceProfile:
55
transposeLayoutWithOrientation:true
66
isGestureMode:false
77
isLandscape:true
8-
isMultiWindowMode:false
8+
isExternalDisplay:false
99
isTwoPanels:false
1010
isLeftRightSplit:true
1111
windowX: 0.0px (0.0dp)
@@ -67,8 +67,8 @@ DeviceProfile:
6767
allAppsBorderSpacePxY: 42.0px (16.0dp)
6868
numShownAllAppsColumns: 5
6969
allAppsPadding.top: 74.0px (28.190475dp)
70-
allAppsPadding.left: 0.0px (0.0dp)
71-
allAppsPadding.right: 0.0px (0.0dp)
70+
allAppsPadding.left: 32.0px (12.190476dp)
71+
allAppsPadding.right: 32.0px (12.190476dp)
7272
allAppsLeftRightMargin: 0.0px (0.0dp)
7373
hotseatBarSizePx: 252.0px (96.0dp)
7474
mHotseatColumnSpan: 5
@@ -117,7 +117,6 @@ DeviceProfile:
117117
overviewActionsTopMarginPx: 0.0px (0.0dp)
118118
overviewActionsHeight: 0.0px (0.0dp)
119119
overviewActionsClaimedSpaceBelow: 0.0px (0.0dp)
120-
overviewActionsButtonSpacing: 0.0px (0.0dp)
121120
overviewPageSpacing: 0.0px (0.0dp)
122121
overviewRowSpacing: 0.0px (0.0dp)
123122
overviewGridSideMargin: 0.0px (0.0dp)

tests/assets/dumpTests/DeviceProfileDumpTest/tabletLandscape.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ DeviceProfile:
55
transposeLayoutWithOrientation:false
66
isGestureMode:true
77
isLandscape:true
8-
isMultiWindowMode:false
8+
isExternalDisplay:false
99
isTwoPanels:false
1010
isLeftRightSplit:true
1111
windowX: 0.0px (0.0dp)
@@ -117,7 +117,6 @@ DeviceProfile:
117117
overviewActionsTopMarginPx: 0.0px (0.0dp)
118118
overviewActionsHeight: 0.0px (0.0dp)
119119
overviewActionsClaimedSpaceBelow: 0.0px (0.0dp)
120-
overviewActionsButtonSpacing: 0.0px (0.0dp)
121120
overviewPageSpacing: 0.0px (0.0dp)
122121
overviewRowSpacing: 0.0px (0.0dp)
123122
overviewGridSideMargin: 0.0px (0.0dp)

tests/assets/dumpTests/DeviceProfileDumpTest/tabletLandscape3Button.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ DeviceProfile:
55
transposeLayoutWithOrientation:false
66
isGestureMode:false
77
isLandscape:true
8-
isMultiWindowMode:false
8+
isExternalDisplay:false
99
isTwoPanels:false
1010
isLeftRightSplit:true
1111
windowX: 0.0px (0.0dp)
@@ -117,7 +117,6 @@ DeviceProfile:
117117
overviewActionsTopMarginPx: 0.0px (0.0dp)
118118
overviewActionsHeight: 0.0px (0.0dp)
119119
overviewActionsClaimedSpaceBelow: 0.0px (0.0dp)
120-
overviewActionsButtonSpacing: 0.0px (0.0dp)
121120
overviewPageSpacing: 0.0px (0.0dp)
122121
overviewRowSpacing: 0.0px (0.0dp)
123122
overviewGridSideMargin: 0.0px (0.0dp)

tests/assets/dumpTests/DeviceProfileDumpTest/tabletPortrait.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ DeviceProfile:
55
transposeLayoutWithOrientation:false
66
isGestureMode:true
77
isLandscape:false
8-
isMultiWindowMode:false
8+
isExternalDisplay:false
99
isTwoPanels:false
1010
isLeftRightSplit:false
1111
windowX: 0.0px (0.0dp)
@@ -117,7 +117,6 @@ DeviceProfile:
117117
overviewActionsTopMarginPx: 0.0px (0.0dp)
118118
overviewActionsHeight: 0.0px (0.0dp)
119119
overviewActionsClaimedSpaceBelow: 0.0px (0.0dp)
120-
overviewActionsButtonSpacing: 0.0px (0.0dp)
121120
overviewPageSpacing: 0.0px (0.0dp)
122121
overviewRowSpacing: 0.0px (0.0dp)
123122
overviewGridSideMargin: 0.0px (0.0dp)

tests/assets/dumpTests/DeviceProfileDumpTest/tabletPortrait3Button.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ DeviceProfile:
55
transposeLayoutWithOrientation:false
66
isGestureMode:false
77
isLandscape:false
8-
isMultiWindowMode:false
8+
isExternalDisplay:false
99
isTwoPanels:false
1010
isLeftRightSplit:false
1111
windowX: 0.0px (0.0dp)
@@ -117,7 +117,6 @@ DeviceProfile:
117117
overviewActionsTopMarginPx: 0.0px (0.0dp)
118118
overviewActionsHeight: 0.0px (0.0dp)
119119
overviewActionsClaimedSpaceBelow: 0.0px (0.0dp)
120-
overviewActionsButtonSpacing: 0.0px (0.0dp)
121120
overviewPageSpacing: 0.0px (0.0dp)
122121
overviewRowSpacing: 0.0px (0.0dp)
123122
overviewGridSideMargin: 0.0px (0.0dp)

0 commit comments

Comments
 (0)