Commit Graph

2553 Commits

Author SHA1 Message Date
Jagrut Desai
0dc1b79fdf Tracing for AddConfigWidgetTest
Test: none
Bug: 276794291
Flag: not needed
Change-Id: I56c4279cf7af2ec704aec8950a3ba7781f8c6b12
2023-04-24 13:12:41 -07:00
Vadim Tryshev
ca83c69dc4 Merge "Making it clear that a test sees the keyguard for the first time." into udc-dev 2023-04-21 19:16:43 +00:00
Andrew Cole
d59c600411 Merge "Screen recording flakey test" into udc-dev 2023-04-21 17:51:56 +00:00
Vadim Tryshev
2b24e53531 Merge "Better diagnose Launcher state when there is an open folder." into udc-dev 2023-04-21 00:39:15 +00:00
Andrew Cole
0d775d3508 Merge "Unit testing ButtonDropTarget" into udc-dev 2023-04-20 23:35:49 +00:00
vadimt
2e1d2c32ed Making it clear that a test sees the keyguard for the first time.
This help to find a test which bugreport may still contain a recent crash in SysUI. This is the tests that prints "for the first time = true"

Test: presubmit
Bug: 187761685
Change-Id: Ic24a1d6f4ba36e117df2166c57bbc0a1d021cc7d
2023-04-20 14:14:23 -07:00
vadimt
9f49e5f33f Better diagnose Launcher state when there is an open folder.
Without this change, the diag is:
visible state is LaunchedApp (active app: com.google.android.apps.nexuslauncher)

https://android-build.corp.google.com/test_investigate/?testResultId=TR37728586113816784&invocationId=I13000010147719553&tab=trace

Test: presubmit
Bug: 187761685
Change-Id: Ia2425a09408d7e1a9c22d0a65fc4ab31cc793a46
2023-04-20 13:59:39 -07:00
Andrew Cole
44898c3db4 Unit testing ButtonDropTarget
Originally there was a bug in a method (isTextClippedVertically) in ButtonDropTarget. While attempting to write a unit test it became necessary to refactor ButtonDropTarget and DeleteDropTarget to decouple them from their dependency on launcher in order to allow for a unit test to be written

The pattern we are introducing here is to decouple Launcher from a controller, in order to facilitate easier testing.
Instead of calling Launcher.getLauncher() we call the method through ActivityContext, which has a testing wrapper already defined. Here is a diagram that explains the old and new pattern

Design Pattern: https://screenshot.googleplex.com/7apiE2DaGDrFzy9.png

Test: isTextClippedVerticallyTest
Bug: b/274402490

Change-Id: I1f3003d0b62dddbceb6e492b15aa5d7352d3a293
2023-04-20 11:22:27 -07:00
Sebastián Franco
051a1e35c8 Merge "Make functions private to keep TAPL design consistent" into udc-dev 2023-04-19 23:45:14 +00:00
Brian Isganitis
91b0e2d6d1 Merge "Properly compute scroll for Taskbar All Apps." into udc-dev 2023-04-19 14:36:21 +00:00
Sebastian Franco
c42520965f Make functions private to keep TAPL design consistent
Bug: 266116487
Test: compiles
Change-Id: I22b612e4bc1a7424af3702474b709426fcfcb6ef
2023-04-18 13:43:10 -07:00
Brian Isganitis
01be7eeb57 Properly compute scroll for Taskbar All Apps.
It was hooked up to Launcher All Apps scroll, which is a separate
instance from Taskbar.

Test: atest WMShellFlickerTests
Fix: 270770472
Change-Id: I14b11c8b5f1143886dd5976a12bba9e4ee66aa96
2023-04-17 18:19:54 +00:00
Sunny Goyal
ce953a36ec Moving ModelDbController from LauncehrProvider to LauncherModel
Migrating some of the class to use the controller directly, will
update the remaining calls in follow up cls

Bug: 277345535
Test: Presubmit
Change-Id: I8edc7c43665f94702ac64bd92932d6c94cb544a4
2023-04-14 14:13:17 -07:00
Andrew Cole
89aea61bc4 Screen recording flakey test
Adding back the screen recording on the test to see more information about what is failing

Test: Manual
Bug: b/258071914
Change-Id: I6114c66f3fc78e9713cd9f13fd8d8008d9921a32
2023-04-14 20:21:01 +00:00
Sunny Goyal
348e518b2c Merge "Using a runtime generated layout for tests instead of defining xml" into udc-dev 2023-04-14 18:12:57 +00:00
Sebastián Franco
df812dfd91 Merge "Parsing test boards from text files to be able to add more and bigger tests" into udc-dev 2023-04-13 20:32:34 +00:00
Sebastian Franco
e7c3d3d4ce Parsing test boards from text files to be able to add more and bigger tests
It also adds an assets folder inside of Launcher3 tests.

It also fixes a bug in fullReorder.

Test: atest ReorderWidgets
Flag: none
Bug: 229292911
Change-Id: I7dadd42a3057d353326691163bb7db71a2e9dcc4
2023-04-13 17:14:51 +00:00
Sunny Goyal
ab2f808196 Using a runtime generated layout for tests instead of defining xml
This allows support for easily setting up default layouts

Bug: 277345535
Test: Presubmit
Flag: N/A
Change-Id: I1c089d60ac3f8add8d7e1060d343e04d30afe094
2023-04-12 22:54:14 +00:00
Sunny Goyal
eb27546cc3 Removing remaining code around ENABLE_DATABASE_RESTORE
ENABLE_DATABASE_RESTORE feature is already removed
Also migrating some tests from BackupRestoreTest to RestoreDbTaskTest

Bug: 270392706
Test: Presubmit
Flag: N/A
Change-Id: I71822bbc2232008b3d2b4b9fbed0db5d889591e4
2023-04-12 15:52:35 -07:00
Sunny Goyal
1ae46ca868 Moving all DB management logic from LauncherProvider into a separate class
This would make it easier to move the controller to LauncherModel

Bug: 277345535
Test: Presubmit
Flag: N/A
Change-Id: I4d044cf41361f400968ef65e18de5d3976fcdec7
2023-04-11 11:46:40 -07:00
Sunny Goyal
f8e0e7270e Merge "Removing support for adding legacy shortcuts." into udc-dev 2023-04-11 14:39:53 +00:00
Vadim Tryshev
f1fe64eb95 Merge "Not spamming logs with "Hierarchy before swiping up to home"" into udc-dev 2023-04-11 02:04:50 +00:00
vadimt
22b1daea5e Not spamming logs with "Hierarchy before swiping up to home"
Bug: 260260325
Test: presubmit
Change-Id: I74e0729ae62656a235eb71e443a2ddf9a6cae3f9
2023-04-10 15:19:48 -07:00
Sunny Goyal
84b48d8deb Removing support for adding legacy shortcuts.
All existing legacy shortcuts will be migrated one-time to deep shortcuts
This shortcuts are pinned under the Launcher package, with custom badging

Bug: 275875209
Test: Updated unit tests
Flag: N/A
Change-Id: I7da001f724776ad8d6c807517b7e4e259de626c2
2023-04-10 12:28:52 -07:00
TreeHugger Robot
643253d433 Merge "Moving DatabaseHelper to it's own class outside of Launcher provider" into udc-dev 2023-04-10 18:33:39 +00:00
Sunny Goyal
ba2795827b Moving DatabaseHelper to it's own class outside of Launcher provider
Bug: 277345535
Test: Presubmit
Flag: N/A
Change-Id: Ib8c94ceb954172dc27e357be2face06d50d399dd
2023-04-10 09:15:18 -07:00
Sam Saccone
a61ac589a3 Merge "Failing all e2e tests after seeing a lock screen without additional checks for the lock screen" into udc-dev 2023-04-08 22:21:10 +00:00
vadimt
160c8217d5 Failing all e2e tests after seeing a lock screen without additional checks for the lock screen
This will speed up the tests.

Test: presubmit
Bug: 276755129
Change-Id: I7170ea76d3e013a8b55187432809815c3713e6c7
2023-04-06 15:52:53 -07:00
Charlie Anderson
471b88269f Prevents cropping of shortcuts in the app popup menu by limiting rows to available screen space.
- Limit the number of shortcut rows shown to what will fit the screen.
 - Fix drag testDragShortcut so that it works for all screen sizes.
 - Prevent cropping and misalignment of shortcut text.

Bug: 247880037
Fixes: 275115239
Test: locally on different devices, and with Display Size set to different sizes
Change-Id: I18b27ec302c34d1d801171ab18c64169a9f252ee
2023-04-06 15:23:38 -04:00
TreeHugger Robot
75f7bbc150 Merge "Allow grids to specify if we should start align taskbar in 3 button nav." into tm-qpr-dev am: 65ac592f40 am: a2b770b484
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/22361600

Change-Id: I41eea8cf3fa15c9c5c3f3184f2ba75318332f623
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-04-05 22:36:14 +00:00
Sunny Goyal
8382546a11 Merge "Removing support for legacy shortcuts from default layouts" into udc-dev 2023-04-05 22:26:36 +00:00
TreeHugger Robot
a2b770b484 Merge "Allow grids to specify if we should start align taskbar in 3 button nav." into tm-qpr-dev am: 65ac592f40
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/22361600

Change-Id: I71c7f33286ccfa770f87b812c8ec27fa4ecb25ed
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-04-05 22:06:49 +00:00
Andrew Cole
6598fab10c Merge "Improving a flakey uninstall from allapps test." into udc-dev 2023-04-05 20:27:10 +00:00
Sunny Goyal
afaa8f0bfe Removing support for legacy shortcuts from default layouts
Launcher will only allow deep shortcuts to be pinned on homescreen.

Bug: 275875209
Test: Updated tests
Flag: N/A
Change-Id: I4f2674deb9cd81dd07d5d537f35a51b030a183da
2023-04-05 20:20:34 +00:00
Jon Miranda
04f051045c Allow grids to specify if we should start align taskbar in 3 button
nav.

Bug: 259712417
Test: check layout on tablet
      check layout on multi_display devices

Change-Id: I282f51e5d76a30e9ad9d8c52d03d4853e965d65a
2023-04-05 10:29:51 -07:00
Andrew Cole
78e1461748 Improving a flakey uninstall from allapps test.
Previously the test froze the all apps list before the uninstall action, but what we are testing here is that the all apps list does change. Also included is a small refactor to use the same wait method for this test and a second test.

Test: Ran Locally on Device
Bug: b/258071914
Change-Id: Ic18be39130fbd7b7e1214d6fc60c1afa30ddf078
2023-04-05 10:16:00 -07:00
Sunny Goyal
6b543872fb Merge "Removing unnecessary device sumaltion code" into tm-qpr-dev am: 08a13d6aae am: e2d73bf57d
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/22432108

Change-Id: I007c3bcd9a5d5dd8c986efc089420f73f7bad18f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-04-04 17:50:24 +00:00
Sunny Goyal
e2d73bf57d Merge "Removing unnecessary device sumaltion code" into tm-qpr-dev am: 08a13d6aae
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/22432108

Change-Id: I883a06a1bf44f7f25928b1355637bd3a8b5d7bdc
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-04-04 17:20:58 +00:00
TreeHugger Robot
0770b619ed Merge "Ensuring that badge override is respected even if component name is set on the Shortcut" into udc-dev 2023-04-04 00:40:14 +00:00
Sunny Goyal
076e04bcc2 Removing unnecessary device sumaltion code
Bug: 276774148
Test: Verified on device
Change-Id: Icb8c2e7649e5b0e107af184b63f7e30f2df717bd
2023-04-03 12:38:52 -07:00
Sunny Goyal
899bf30fe8 Ensuring that badge override is respected even if component name
is set on the Shortcut

Bug: 276319271
Test: atest IconCacheTest
Flag: N/A
Change-Id: I33802ecd23485ba092f842ec3c3d58e2fc286f92
2023-04-03 08:31:02 -07:00
TreeHugger Robot
7163918dd0 Merge "Show suggested widgets header only when there are suggested widgets" into udc-dev 2023-04-02 22:47:07 +00:00
Jeremy Sim
9a9d4ce653 Merge "App Pairs (behind flag): Add Overview menu item, icon, tests" into udc-dev 2023-04-01 02:05:30 +00:00
Vadim Tryshev
9832afdf2b Merge "Add more logging to debug b/270770472" into udc-dev 2023-04-01 01:58:49 +00:00
Jeremy Sim
9f0a6b8e82 App Pairs (behind flag): Add Overview menu item, icon, tests
This is the first of several patches implementing the App Pairs feature behind a flag.

This patch includes:
- The icon asset for the "Save app pair" menu option
- The menu option, which will appear in the Overview drop-down menu for split pairs
- Some tests ensuring that the menu item appears when appropriate

Flag: ENABLE_APP_PAIRS (set to false)
Bug: 274189428
Test: 2 tests in TaplTestsSplitscreen.java
Change-Id: I174f2c66e7eb6d83ff7fe501eb82cc48e727022c
2023-03-31 17:16:56 -07:00
fbaron
ba3f77be7d Show suggested widgets header only when there are suggested widgets
Bug: 275435999
Test: Verified suggested widgets header doesn't show up unless there are suggested widgets to show
Change-Id: I2ec2ba100d7a6ddc338a36ece75633abba990b2b
2023-03-31 21:45:07 +00:00
vadimt
406a96c1e2 Add more logging to debug b/270770472
Test: presubmit
Bug: 270770472
Change-Id: Ie7c07b7095c7fba0058d9785a1fb47208d09eb21
2023-03-31 13:41:50 -07:00
vadimt
59cc1714ce Demoting WorkProfileTest#testEdu from presubmit due to high flakiness
Test: presubmit
Bug: 243688989
Change-Id: Ib477e9f749a6f7117008d65316f32080c719167c
2023-03-30 17:53:52 -07:00
vadimt
a2918038fc Demoting WorkProfileTest#workTabExists from presubmit due to high flakiness
Test: presubmit
Bug: 243688989
Change-Id: I2edbd94a79d8f66e006ce0087bf4ab617e6ba041
2023-03-30 10:45:01 -07:00
Schneider Victor-tulias
f8f602d76c Merge "Fix TwoPanelWorkspaceTests" into tm-qpr-dev am: 90259a6db4 am: d8e5795131
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/22185922

Change-Id: Ic5d6ce2a870f19c960baab3af8abfb1faee248f1
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-30 17:16:22 +00:00