Commit Graph

164 Commits

Author SHA1 Message Date
Nataniel Borges
c8287a930f [DO NOT MERGE] Sync flicker from master to sc-v2
Flicker on master diverged form sc-v2, to make it easier to debug
flicker issues on sc-v2, push the current version of flicker into sc-v2

Test: atest FlickerTests WMShellFlickerTests
Bug: 188792659
Change-Id: I1c832bf32214b12ba4b708bccfc95cf259324844
2021-09-01 12:06:21 +00:00
Jerry Chang
a99034d9c6 Only run PipLegacySplitScreenTest when it is using legacy split
Ignore PipLegacySplitScreenTest if the system is not using legacy
split by checking config_useLegacySplit which is set to false since
sc-v2 or on jumbojack device. The flag should be deprecated along with
legacy split screen.

Bug: 189245318
Test: atest PipLegacySplitScreenTest
Change-Id: I6243f0b0990265c96867cb7ee87b6bd0b90330c7
2021-08-27 10:06:31 +08:00
TreeHugger Robot
fc7ff7b7e2 Merge "Only run legacy split flicker tests when it is using legacy split" into sc-v2-dev 2021-08-19 07:19:39 +00:00
Jerry Chang
66e7ff7937 Only run legacy split flicker tests when it is using legacy split
Ignore legacy split flicker tests if the system is not using legacy
split by checking config_useLegacySplit which is set to false since
sc-v2 or on jumbojack device. The flag should be deprecated along with
legacy split screen.

Bug: 189245318
Test: pass existing tests
Change-Id: Ic3dfbe849e7fcc9f25e44b7ff37ad00fdee60e9a
2021-08-19 06:01:00 +00:00
Ben Lin
e266d53aa5 Merge "Fix PiP rotation when Shell Transition is on." into sc-v2-dev 2021-08-18 23:48:09 +00:00
Ben Lin
fa097e1fa8 Fix PiP rotation when Shell Transition is on.
Also fixed the associated flicker tests.

Bug: 193565745
Bug: 165793917
Test: atest
Change-Id: I5156aa0236e704d46badd28b8093174a04f329ea
Merged-In: Iebd847ab0d7dc394fc64bb54cdc5262db7b9f1b0
2021-08-18 23:04:04 +00:00
Ben Lin
e920199761 Disable PipLegacySplitScreenTest when Shell Transition is on.
Bug: 193565745
Test: atest
Change-Id: I3055d461ae00d8e0e97e971897d7df24107dfc3f
2021-08-09 17:14:20 -07:00
Nataniel Borges
3dab1eaeec [DO NOT MERGE] Full - Compatibilize winscope with master
Bug: 194813677
Test: none
Change-Id: I88e0e6d5b75ae3511491d6711279b951b3d9c761
2021-07-28 07:23:14 +00:00
Chris Li
56f9dc1299 Skip AppPairs and LegacySplit flicker tests when Shell transition is on
AppPairs: no plan to update to Shell transition soon
LegacySplit: will be replaced by StageSplit in sc-v2

Bug: 183993924
Test: pass existing
Change-Id: I1cd485126356ae5d628b13cc33f883d61430285d
2021-07-11 13:02:01 -07:00
TreeHugger Robot
608a439238 Merge "Split flicker tests into groups" into sc-dev 2021-05-22 09:44:36 +00:00
Nataniel Borges
8aaaeea849 Split flicker tests into groups
The flicker test suite grew and now trigger a treehuger SLO violation. To address this problem create different groups for different tests using: --module-arg <TEST SUITE>:include-annotation:<GROUP>

Where:
   <TEST SUITE> = FlickerTests or WMShellFlickerTests
   <GROUP> = com.android.server.wm.flicker.annotation.Group1 or com.android.server.wm.flicker.annotation.Group2 or com.android.server.wm.flicker.annotation.Group3

For example:

1) to run only tests in the first group in flicker use: `--module-arg FlickerTests:include-annotation:com.android.server.wm.flicker.annotation.Group1`

2) to run only the third group of tests from wmshell flicker: ``--module-arg FlickerTests:include-annotation:com.android.server.wm.flicker.annotation.Group3`

Bug: 180620475
Test: atest FlickerTests WMShellFlickerTests with the respective parameters
Change-Id: I82f668713ba262bafe2758e2c618bfc060cc2c8a
2021-05-20 09:36:44 +02:00
Chris Li
30248a1952 Determine whether to support activities in multi window (9/n)
When a Task is detached but is still stored as a recent Task, it should
be allowed to launched into split screen.

Bug: 176061101
Test: atest WMShellFlickerTests:EnterSplitScreenFromDetachedRecentTask
Test: atest WmTests:RecentTasksTest
Change-Id: Ic72901ca76f4acb6e68926062675ecc290b399be
2021-05-18 21:07:52 +00:00
Jerry Chang
68667bdd3a Merge "Fix wrong split bounds in legacy split flicker tests" into sc-dev 2021-05-14 02:29:18 +00:00
Jerry Chang
93edc1eae5 Fix wrong split bounds in legacy split flicker tests
Fix: 188013792
Test: passed presubmit
Change-Id: I675633a078d172f9c8cd836980658c4f2aa2d246
2021-05-13 16:23:42 +08:00
Chris Li
43d99647e4 Determine whether to support activities in multi window (5/n)
Update Task/ActivityRecord to use the new elgibility check and update
tests

Bug: 176061101
Test: pass existing
Change-Id: Ibb78a43d5901a604b02904be0a0bfdc6da0eb421
2021-05-11 04:20:49 +00:00
Chris Li
f9c4ee1fd3 Merge "Move legacy split screen flicker tests for non-resizable to presubmit" into sc-dev 2021-04-29 17:49:15 +00:00
Nataniel Borges
8a26f00f1f Merge "Fix pip window visibility assertions" into sc-dev 2021-04-29 15:51:59 +00:00
TreeHugger Robot
c8a0871269 Merge "Disable flaky app pair assertions" into sc-dev 2021-04-29 15:18:23 +00:00
Nataniel Borges
4b2f1da126 Fix pip window visibility assertions
1) Fix `Could not find: PipApp`, the test previously used the launcher name, instead of the window name for assertion

2) The command previously missed a `verify` call to actually execute the assertion

Bug: 186115871
Bug: 186445782
Test: atest FlickerTests WMShellFlickerTests
Change-Id: Ie9274e273bcda2be24491705cd28d7dc0d5ea5db
2021-04-29 12:02:31 +02:00
Chris Li
2e02036650 Move legacy split screen flicker tests for non-resizable to presubmit
Fix: 182235458
Test: pass existing
Change-Id: Ia139972beae25fcb60dc68c11c2d50efc38e00cf
2021-04-28 16:46:58 +00:00
TreeHugger Robot
da2192eacf Merge "Disable flaky pip/app close tests (flicker)" into sc-dev 2021-04-28 10:13:57 +00:00
Nataniel Borges
d825929c73 Disable flaky app pair assertions
Assertion is flaky in presubmit

Bug: 186510496
Test: atest FlickerTests WMShellFlickerTests
Change-Id: Ic796c86d555376283adbcdb06ea80c6d9ddbfe07
2021-04-28 10:05:16 +02:00
Chris Li
4bc72c96db Merge "Fix EnterSplitScreenNotSupportNonResizable flaky" into sc-dev 2021-04-27 19:50:35 +00:00
Nataniel Borges
73e2773099 Disable flaky pip/app close tests (flicker)
Some tests are still flaky and affecting presubmit

Bug: 185400889
Test: atest FlickerTests WMShellFlickerTests
Change-Id: I477799646791c69b71c6f29d71e87caba900a983
2021-04-27 14:58:56 +02:00
Chris Li
55a68d161b Fix EnterSplitScreenNotSupportNonResizable flaky
Before, it called openQuickstep before canSplitScreen, but the later one
is also calling openQuickstep. This caused the recent is pressed twice
to introduce the flakness.

Test: atest WMShellFlickerTests:EnterSplitScreenNotSupportNonResizable
Bug: 182235458
Change-Id: Iba5af5114fd8883b73d78ac34e6f891ee8ca798f
2021-04-23 21:50:14 -07:00
Nataniel Borges
91b6830e38 Disable flaky flicker tests
Some tests are still flaky and affecting presubmit

Bug: 185400889
Bug: 186119282
Bug: 186115871
Test: atest FlickerTests WMShellFlickerTests
Change-Id: Ie4e21d01d5ea7586f88470543321ce26ed74afa6
2021-04-22 19:10:04 +02:00
Chris Li
1ca437909f Fix flaky legacy split screen flicker tests
Bug: 182235458
Test: pass existing
Change-Id: I20e957b0bfcacb37c1ad72b4a8cea155eeee911a
2021-04-19 18:25:26 -07:00
Nataniel Borges
f226bc0878 Remove quicksearchbox from home window list
Previously Winscope considered only the `isVisible` property to determine if the window was visible or not. This failed in cases such as `com.google.android.googlequicksearchbox/android.app.ContextImpl` when launching apps, where `isVisible=true` and `alpha=0`

Bug: 181630910
Bug: 182720234
Test: atest FlickerTests WMShellFlickerTests
Change-Id: I75fab0c6de02e43265002986901353f8e230baa5
2021-04-15 17:50:34 +02:00
Nataniel Borges
c258d7f4ca Disable some trace assertions
Previously some assertions didn't run on the whole trace because of a missing `forAllEntries` statement in the library. When activating this statement these tests fail and should be disabled.

Test: atest FlickerTests WMShellFlickerTests
Bug: 183547024
Bug: 181630910
Change-Id: I28f92e2d9de1a5465a4da5971c438bc4c0b311f9
2021-04-13 20:55:39 +02:00
Nataniel Borges
e852b071ff Fix use of NavigationModeRule on flicker
The method was ignored before and now should be activated to enable 3 button mode. Some tests become flaky in 3-button mode and should be disabled for the moment.

Test: atest FlickerTests WMShellFlickerTests
Bug: 162925924
Change-Id: Ife24ad85c302da6fc193f1a5a226722cfed51b2b
2021-04-12 15:15:56 +02:00
Hongwei Wang
c5d831fea1 Flicker test for PiP and launcher shelf height
PipMovesInAllApps was intended to test the PiP window movement when the
shelf height of Launcher changes and breaks with the recent `Device
search` feature that opening all-apps in Launcher triggers both IME and
shelf height change.

Since PipKeyboardTest has covered PiP movement with IME, reimplement
this by launching a new app instead of going to all-apps and also rename
this test for its intention.

Bug: 184050344
Test: atest WMShellFlickerTests:PipShelfHeightTest
Change-Id: I102ea95e6e91c9707b73587282702b868eb705fb
2021-03-31 13:38:10 -07:00
Nataniel Borges
400197ade7 Merge changes from topic "remove-all-tasks" into sc-dev
* changes:
  Ensure apps not running on cold launch test
  Remove all tasks before flicker tests
2021-03-31 16:54:05 +00:00
Nataniel Borges
2935ef01dc Merge "Move Pip assertions to flickerlib" into sc-dev 2021-03-31 07:54:24 +00:00
Nataniel Borges
61c3ea1789 Move Pip assertions to flickerlib
Previously the assertions were part of WMShell, however it is easier to keep them in the library as they can be used in other projects

Test: atest FlickerTests WMShellFlickerTests
Bug: 162925924
Change-Id: Ia6ca7cce1da81be2b73166acce40218bc304a77a
2021-03-30 23:11:41 +02:00
Hongwei Wang
6c9640f8b3 Merge "Disable PipMovesInAllApps temporarily" into sc-dev 2021-03-30 19:27:00 +00:00
Nataniel Borges
ba72075844 Remove all tasks before flicker tests
Ensures no other tasks are executing (cleanup) when a flicker test states to mitigate flakiness

Test: atest FlickerTests WMShellFlickerTests
Bug: 162925924
Change-Id: I84f712c8aba13ac845b9467f6c9753bc91e21a27
2021-03-30 21:19:08 +02:00
Hongwei Wang
722871b3e4 Disable PipMovesInAllApps temporarily
Test's currently failing due to the new `device search`, disable for
now to unblock presubmit and re-enable once we have a working solution.

Bug: 184050344
Test: atest WMShellFlickerTests:com.android.wm.shell.flicker.pip
Change-Id: I6b75ea213b442400090ee0a3f2b7e46ee5ecd395
2021-03-30 17:01:41 +00:00
Nataniel Borges
887a3c9d38 Introduce a subject to assert changes over rectangles
In several flicker tests it is necessary to check if a window or layer position is moving or resizing.

To facilitate these checks this CL introduces RectSubject (accessible through WindowStateSubject and LayerSubject) to assert rectangle behaviors

Bug: 174238224
Test: atest FlickerTests WMShellFlickerTests
Change-Id: Id568fd9dbd59f176eeb84323c321553221932685
2021-03-29 22:33:41 +02:00
Chris Li
667d242404 Merge "Fix non-resizable split flicker tests" into sc-dev 2021-03-19 03:19:26 +00:00
Chris Li
c40cb1103a Fix non-resizable split flicker tests
1. Update the flag of DEVELOPMENT_ENABLE_NON_RESIZABLE_MULTI_WINDOW
during tests.

2. Before, the tests only checked whether the app window/layer became
visible/invisible, which could also happen during opening recent. Now,
we also check the visibility at the end.

Bug: 182235458
Test: atest WMShellFlickerTests
Change-Id: Ibc7b359d600a0e4105cc3a84b3111d59813eb9f1
2021-03-18 13:35:54 -07:00
Nataniel Borges
1a3724eced Promote stable PIP app tests to presubmit
These flaky tests have been stable for the past week and can be promoted

Test: atest WMShellFlickerTests:com.android.wm.shell.flicker.pip
Bug: 171049720
Bug: 167521849
Change-Id: Ibd78e9d9e53a5712ca781b265b1b65c830a74c08
2021-03-18 11:10:32 +01:00
Nataniel Borges
8b15b01c43 Remove Snapshot and Splash Screen from consecutive entry check
It is already possible to ignore windows/layers on the verification of  visibleWindowsShownMoreThanOneConsecutiveEntry and visibleLayersShownMoreThanOneConsecutiveEntry. However many tests need to manually add the Snapshot and Splash Screen entries.

Those entries are not guaranteed to show for more than 1 entry, they depend on the app behavior and when the SF actually renders the information sent by WM.

This CL removes those windows by default from the verification and refactor the tests to make it easier to update in the future

Test: atest FlickerTests WMShellFlickerTests
Bug: 182720234
Change-Id: I0e3346e078515b3e9a2065256ac04696acfa59fb
2021-03-16 10:26:55 +01:00
Nataniel Borges
1f9f16f880 Merge "Promote PIP postsubmit tests to presubmit" into sc-dev 2021-03-15 16:03:48 +00:00
Chris Li
f834092444 Allow non-resizable to enter split screen from recent
Before, LegacySplitScreen is not allowing non-resizable to enter split
screen. Now, it also checks supportsNonResizableMultiWindow.

Fix: 181377395
Bug: 176061101
Test: manual
Change-Id: Iae4c65b5c8b0a139dbf8af55caba9f6c99d1f470
2021-03-12 16:04:11 -08:00
Nataniel Borges
920cf61139 Merge "New enter pip assertion" into sc-dev 2021-03-12 16:35:46 +00:00
Nataniel Borges
575f4bf38f Merge "Generalize pip transitions and assertions" into sc-dev 2021-03-12 16:34:52 +00:00
Nataniel Borges
bfc834eeea Merge "Generalize apppairs assertions" into sc-dev 2021-03-12 16:34:42 +00:00
Nataniel Borges
9bc15837b6 Promote PIP postsubmit tests to presubmit
The tests have been stable for the past 2 weeks in postsubmit and can be promoted to presubmit

Test: atest FlickerTests:com.android.wm.shell.flicker.pip
Bug: 174238224
Change-Id: Ie7cbd56940e4b5eacd25ba38d1fd0a5966b9a7e9
2021-03-12 15:05:34 +01:00
Nataniel Borges
8923c65435 Merge "Log WM trace on frame instead of transaction" into sc-dev 2021-03-12 09:40:15 +00:00
Jorge Gil
fa63935a61 Merge "Update PIP menu accessiblity bounds when it is moved" into sc-dev 2021-03-10 23:51:52 +00:00