Commit Graph

11864 Commits

Author SHA1 Message Date
JW Wang
94d0377b60 Merge "Remove tests (2/n)" 2021-08-03 05:52:43 +00:00
JW Wang
2f582b9d4a Remove tests (2/n)
Remove tests that have been migrated to CTS.

Bug: 194971428
Test: m RollbackTest
Change-Id: Ib880b067b93396e097b3bbe6aca004b524d8833f
2021-08-02 17:21:57 +08:00
Ioana Moraru
007709c3a8 Merge "Add assertions for two activities transition" 2021-07-30 18:05:09 +00:00
Ioana Moraru
fbab19d794 Add assertions for two activities transition
Start fullscreen activity A, then start another fullscreen activity B in the same task, finish B so there should back to A.

Test: atest FlickerTests:ActivitiesTransitionTest
Bug: 167521780
Change-Id: I82a065f15ad7109c74d3f4c8c5193ed6a4743134
2021-07-30 10:31:56 +00:00
Ioana Moraru
a2c1839bcd Move assertions for non-resizeable application
Move the tests for non-resizeable application from postsubmit to
presubmit

Bug: 167521668
Test: atest FlickerTests:OpenAppNonResizeableTest
Change-Id: If25f813975204772734331ff5ae686eeb1aa9f4c
2021-07-29 10:40:47 +00:00
Ioana Moraru
a9f1d762a1 Merge "Add assertions for non-resizeable application" 2021-07-28 18:54:31 +00:00
Ioana Moraru
014d3f96dc Add assertions for non-resizeable application
Actions:
1. Lock phone
2. Launch app

Assertions:
1. app window not visible start, window appears, app window visible at the end
2. app layer not visible start, app layer appears, app layer visible at the end
3. launcher visible at start, launcher disappears, launcher invisible at the end

Bug: 167521668
Test: atest FlickerTests:OpenAppNonResizeableTest
Change-Id: I36aa6491eebcfa677c0c2a439e8c2aa105377d4e
2021-07-28 16:13:17 +00:00
Kohsuke Yatoh
406226fd43 Merge "Rename NotoColorEmojiTtf module." 2021-07-27 22:23:49 +00:00
Kohsuke Yatoh
5b1bac7a16 Rename NotoColorEmojiTtf module.
Bug: 191914223
Test: atest UpdatableSystemFontTest
Change-Id: Ic79290beb5d8d24d8835a808de90cb820d774003
2021-07-22 18:58:15 +00:00
Nikita Ioffe
9e0f4ac414 Merge changes from topic "apex-installers-restriction" into sc-dev am: e8b129351c am: 476c20cf84
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15347597

Change-Id: Ia18fd231d7bba4fb168a4c7e2419ef26b9baa099
2021-07-22 17:22:48 +00:00
Nikita Ioffe
db9892300e Reject non-staged APEX install if there is staged install of same APEX
There is a interesting interaction between staged and non-staged
installs of the same APEX. Let's say an installer staged v1 -> v2 APEX
update, and then does a non-staged update to v3. After device is
rebooted, apexd will apply the staged v1 -> v2 session, silently
downgrading an APEX from v3.

For apks, this problem is solved by storing an expected version. When an
APK session is being applied during boot, Package Manager will check if
the currently installed version is equal to the expected one stored in
the staged session. If they mismatch, an install is failed.
Unfortunately, implementing the same logic in apexd will require a
non-trivial refactoring which is too late to do in S. Instead we are
just going to fail the non-staged installation.

Test: atest StagedInstallInternalTest
Bug: 187864524
Change-Id: I9000f40cede9a324a5059a09deb8eb5be13b21f9
2021-07-22 12:05:41 +01:00
Nikita Ioffe
e501fd8379 Restrict what APEXes different installers can update
* Mainline APEXes can only be updated by a modulesInstaller (an entry
in whitelisted-staged-installer.xml with isModulesInstaller="true")

* The whitelisted-staged-installer.xml file can have only one entry with
isModulesInstaller="true"

* Vendor APEXes can only be updated by an installer defined in the
corresponding entry in vendor-apex-allowlist.xml.

BYPASS_INCLUSIVE_LANGUAGE_REASON=existing occurrences

Test: atest StagedInstallInternalTest
Test: atest GtsStagedInstallHostTestCases
Test: atest CtsRollbackManagerHostTestCases
Test: atest CtsStagedInstallHostTestCases
Bug: 190802380
Change-Id: I729abb5153df079fb6885016a4b41d0acc827e3c
2021-07-21 16:44:42 +01:00
Benedict Wong
801a4cfaf7 Merge "Set TRANSPORT_PRIMARY for VCN NetworkOffers and NetworkAgents" am: d92daec786 am: 697971f693 am: 2a1b0ab7cd am: 730d70a7f8
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1772025

Change-Id: Ic9a3f83b08568027b39aee1274e6553f9fea9654
2021-07-21 02:31:19 +00:00
Benedict Wong
730d70a7f8 Merge "Set TRANSPORT_PRIMARY for VCN NetworkOffers and NetworkAgents" am: d92daec786 am: 697971f693 am: 2a1b0ab7cd
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1772025

Change-Id: Id69848c8f94771414b18cab1536d29e0d43aab3d
2021-07-21 02:18:28 +00:00
Benedict Wong
2a1b0ab7cd Merge "Set TRANSPORT_PRIMARY for VCN NetworkOffers and NetworkAgents" am: d92daec786 am: 697971f693
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1772025

Change-Id: I3d678a8d3315f884bacfd3052218416604bf3e2c
2021-07-21 02:05:47 +00:00
Benedict Wong
d92daec786 Merge "Set TRANSPORT_PRIMARY for VCN NetworkOffers and NetworkAgents" 2021-07-21 01:29:25 +00:00
Benedict Wong
8d6f7c7280 Set TRANSPORT_PRIMARY for VCN NetworkOffers and NetworkAgents
This change sets TRANSPORT_PRIMARY for all NetworkScore objects passed
to ConnectivityService by the VCN. Without this patch, a VCN in safe
mode will never get any NetworkRequests, since the new Policy-based
NetworkRanker always prioritizes a existing satisfier of a network,
regardless of score. However, a higher-priority policy check ensures
that a TRANSPORT_PRIMARY request is used if it exists. This changes the
VCN to utilize that functionality.

Bug: 194122634
Test: atest FrameworksVcnTests
Change-Id: I3a298a6c4c594c6e224f3f05764614802c00e9b0
2021-07-21 00:44:19 +00:00
Mohammad Samiul Islam
018d6bcbb6 Merge "Test apexd behaves correctly when not in fs-checkpoint mode" into sc-dev am: b713ec62bb am: 1d508e5822
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15302099

Change-Id: If3fc3715d1b336aa8475cc5a73fd52c10ed1c291
2021-07-20 18:16:22 +00:00
Mohammad Samiul Islam
7989a89b56 Merge "Test apexd behaves correctly when not in fs-checkpoint mode" into sc-dev am: b713ec62bb am: 7e0cbf4d28
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15302099

Change-Id: I29f6106e32073af86d466a37450ae28c4b09632e
2021-07-20 18:14:34 +00:00
Mohammad Samiul Islam
7e0cbf4d28 Merge "Test apexd behaves correctly when not in fs-checkpoint mode" into sc-dev am: b713ec62bb
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15302099

Change-Id: I25a8ee1135352b2a5ccc201e7652011782a35991
2021-07-20 18:13:52 +00:00
Mohammad Samiul Islam
e807f57d9a Merge "Test apexd behaves correctly when not in fs-checkpoint mode" into sc-dev am: b713ec62bb
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15302099

Change-Id: I2edfb53a54d4d784296eb648be8d2cf29b542250
2021-07-20 18:13:47 +00:00
Mohammad Samiul Islam
b713ec62bb Merge "Test apexd behaves correctly when not in fs-checkpoint mode" into sc-dev 2021-07-20 18:02:29 +00:00
Samiul Islam
6d9107a468 Test apexd behaves correctly when not in fs-checkpoint mode
This CL contains two tests:
1) When fs-checkpoint-mode is false, but fs-rollback-mode is true
2) When both modes are false

Bug: 193648282
Test: atest StagedInstallInternalTest
Change-Id: I9c96296343a7f39a65de9e06e8a07d765f832044
2021-07-19 13:54:57 +01:00
Benedict Wong
ff3a9bf309 Merge "Ensure VcnGatewayConnection#isQuitting never gets unset after being set" into sc-dev am: 0df66631c0
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15316004

Change-Id: I151b67855b705197cb832caa32c91cc746569b56
2021-07-17 03:15:31 +00:00
Benedict Wong
0df66631c0 Merge "Ensure VcnGatewayConnection#isQuitting never gets unset after being set" into sc-dev 2021-07-17 02:52:32 +00:00
Benedict Wong
a5565eb79c Merge "Limit VCNs to one running at a given time" into sc-dev am: dd6c887985
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15315835

Change-Id: I9c5c265402ca7b78cf618c61c0d24576cc89260b
2021-07-16 23:40:34 +00:00
Benedict Wong
d3b1e7028a Merge "Ensure VcnGatewayConnection#isQuitting never gets unset after being set" am: fc9e0c982f am: e98f254f96 am: adcba0ef9c am: 0989938dfa
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1768623

Change-Id: If15c97f212dfbcb6504a5005b583dcbde9bcc4f4
2021-07-16 22:46:43 +00:00
Benedict Wong
0989938dfa Merge "Ensure VcnGatewayConnection#isQuitting never gets unset after being set" am: fc9e0c982f am: e98f254f96 am: adcba0ef9c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1768623

Change-Id: Ia129cdf9230d7c77379ed5e9c2a25fdaeb6fc513
2021-07-16 22:31:43 +00:00
Benedict Wong
29b3fdd6b6 Ensure VcnGatewayConnection#isQuitting never gets unset after being set
This change ensures that the VcnGatewayConnection can never abort a
quitting command; specifically, if a non-quitting disconnect request is
processed after a quitting disconnect request, the isQuitting value MUST
continue to stay set (as true).

Failure to OR the values results in orphaned VcnGatewayConnection(s),
and the VCN network thrashing.

Additionally reduce verbosity of local logs, to ensure it better
captures failures and logWtf(s)

Bug: 192776413
Test: atest FrameworksVcnTests
Original-Change: https://android-review.googlesource.com/1768623
Merged-In: Iec8dae701838794261957609bae4e270eaa9cdc7
Change-Id: Iec8dae701838794261957609bae4e270eaa9cdc7
2021-07-16 22:30:25 +00:00
Benedict Wong
adcba0ef9c Merge "Ensure VcnGatewayConnection#isQuitting never gets unset after being set" am: fc9e0c982f am: e98f254f96
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1768623

Change-Id: I418557047f10b0224583f9e99770169356f07fa9
2021-07-16 22:16:36 +00:00
Benedict Wong
e53cbf4df3 Limit VCNs to one running at a given time
This change ensures that there is only ever one VCN running at a given
point in time, and that if the device has switched to using a
subscription in a different subscription group, the VCN will immediately
tear down.

This ensures that when on a DSDS device, when the VCN-enabled
subscription is not the default/active subscription, the other
subscription's network will never be outscored by the VCN, and thus get
torn down.

Bug: 190761448
Test: atest FrameworksVcnTests
Test: Manual testing to ensure common functionality
Original-Change: https://android-review.googlesource.com/1767050
Merged-In: I8031fab7502880d38420058451df41f47567c458
Change-Id: I8031fab7502880d38420058451df41f47567c458
2021-07-16 22:03:37 +00:00
Benedict Wong
fc9e0c982f Merge "Ensure VcnGatewayConnection#isQuitting never gets unset after being set" 2021-07-16 21:29:36 +00:00
Benedict Wong
e8c548fd02 Ensure VcnGatewayConnection#isQuitting never gets unset after being set
This change ensures that the VcnGatewayConnection can never abort a
quitting command; specifically, if a non-quitting disconnect request is
processed after a quitting disconnect request, the isQuitting value MUST
continue to stay set (as true).

Failure to OR the values results in orphaned VcnGatewayConnection(s),
and the VCN network thrashing.

Additionally reduce verbosity of local logs, to ensure it better
captures failures and logWtf(s)

Bug: 192776413
Test: atest FrameworksVcnTests
Change-Id: Iec8dae701838794261957609bae4e270eaa9cdc7
2021-07-16 12:10:08 -07:00
Benedict Wong
6a4035f76f Merge "Limit VCNs to one running at a given time" am: 9e6e3ce643 am: 4d16027790 am: ee52376594 am: d9e09cc69c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1767050

Change-Id: Ie2889987db1c3dfe138d2330784769aaeb10ffaa
2021-07-16 04:01:33 +00:00
Benedict Wong
d9e09cc69c Merge "Limit VCNs to one running at a given time" am: 9e6e3ce643 am: 4d16027790 am: ee52376594
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1767050

Change-Id: Ic19e114d7c51fb7aab0f88771ebd042a744434db
2021-07-16 03:44:36 +00:00
Benedict Wong
ee52376594 Merge "Limit VCNs to one running at a given time" am: 9e6e3ce643 am: 4d16027790
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1767050

Change-Id: I89be4b61ec4e3a7ed24b817acf52a9c58fb5b4f2
2021-07-16 03:27:31 +00:00
Benedict Wong
9e6e3ce643 Merge "Limit VCNs to one running at a given time" 2021-07-16 02:48:06 +00:00
Benedict Wong
3433a8e5d9 Limit VCNs to one running at a given time
This change ensures that there is only ever one VCN running at a given
point in time, and that if the device has switched to using a
subscription in a different subscription group, the VCN will immediately
tear down.

This ensures that when on a DSDS device, when the VCN-enabled
subscription is not the default/active subscription, the other
subscription's network will never be outscored by the VCN, and thus get
torn down.

Bug: 190761448
Test: atest FrameworksVcnTests
Test: Manual testing to ensure common functionality
Change-Id: I8031fab7502880d38420058451df41f47567c458
2021-07-15 12:04:05 -07:00
Nikita Ioffe
ac3fe611be Merge "Fix PackageManager query API's related to rebootless APEX updates" into sc-dev am: 09f8e5de00 am: 838dd43345
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15245533

Change-Id: I535dc0c2c738e4a715c2b86fe6ac2c1f635b3dcc
2021-07-13 00:51:40 +00:00
Nikita Ioffe
838dd43345 Merge "Fix PackageManager query API's related to rebootless APEX updates" into sc-dev am: 09f8e5de00
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15245533

Change-Id: I1373c1a698743b9d9dcc90fc40c158bf528a39ac
2021-07-13 00:35:51 +00:00
Nikita Ioffe
777ee9489f Merge "Treat APEX installs as upgrades" into sc-dev am: bdf97e12ea
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15245531

Change-Id: I415022682ed3d58501a2b7d6c22cce957ddb2db2
2021-07-12 23:48:35 +00:00
Nikita Ioffe
301fc01557 Merge "Treat APEX installs as upgrades" into sc-dev am: bdf97e12ea am: a4c28b230b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15245531

Change-Id: I9e4b75ecfde5311afce9510800d85a46aac01c8e
2021-07-12 23:44:06 +00:00
Nikita Ioffe
05a9da75f4 Merge "Fix PackageManager query API's related to rebootless APEX updates" into sc-dev am: 09f8e5de00 am: 9f2e928f89
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15245533

Change-Id: I66197e2e410ed5d447f79ccb1f6e8ab8baf42909
2021-07-12 20:16:48 +00:00
Nikita Ioffe
99ca20251e Merge "Fix PackageManager query API's related to rebootless APEX updates" into sc-dev am: 09f8e5de00
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15245533

Change-Id: Id4e25ee06ccdee239405ef7e1e8878198aeaac61
2021-07-12 19:37:07 +00:00
Bill Yi
97f19415cd Merge RQ3A.210705.001 to aosp-master - DO NOT MERGE
Merged-In: I867df303b8da1b9748e5a775dd8bf4a1b910c434
Merged-In: Ia19f336f9eca3b493157dcd3ad07d267b6526e8f
Merged-In: Ia19f336f9eca3b493157dcd3ad07d267b6526e8f
Change-Id: I16c6e1ee5e172100a22995ae464c5f2c596d2381
2021-07-12 11:11:15 -07:00
Nikita Ioffe
d981d0facd Merge "Treat APEX installs as upgrades" into sc-dev am: bdf97e12ea am: 5b374f7278
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15245531

Change-Id: I85e6f5deff55d74d0af13f253648bd981239779a
2021-07-12 14:03:25 +00:00
Nikita Ioffe
3e62b8f748 Fix PackageManager query API's related to rebootless APEX updates
There were two bugs:

1. In case of the first update, ApexManager removed information about
  pre-installed version of the APEX.
2. After an update, getPackageInfo cache wasn't invalidated, which
  resulted in getPackageInfo returning stale information.

Bug: 193085724
Test: atest ApexManagerTest
Test: atest StagedInstallInternalTest
Change-Id: I6df7b296cd5d83c93524178f1546855747ea6b07
2021-07-12 13:51:11 +00:00
Nikita Ioffe
a4c28b230b Merge "Treat APEX installs as upgrades" into sc-dev am: bdf97e12ea
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/15245531

Change-Id: Ifd39ecd7a84b8e66676a6ea71bf903fe8d18ebbf
2021-07-12 13:46:16 +00:00
Nataniel Borges
477500adf3 Promote or demote stable and flaky flicker tests
Weekly CL updating the status of flicker tests.

Promote:
- stable postsubmit to presubmit
- stable flaky to postsubmit

Demote:
- unstable presubmit to flaky
- unstable postsubmit to flaky

Test: atest FlickerLibTest FlickerTests WMShellFlickerTests
Bug: 190189685
Bug: 141361128
Change-Id: I8988b9f9e6d92d26b169da91ce98b359bf05336f
2021-07-10 14:40:04 +02:00
Nikita Ioffe
24e3ed6e78 Treat APEX installs as upgrades
It's not allowed to install a completely new APEX, hence APEX
installations should be treated as upgrades.

This change allows holders of INSTALL_PACKAGE_UPDATES permission to
silently install APEX upgrades.

Bug: 193085724
Bug: 190802380
Test: atest StagedInstallInternalTest
Change-Id: Idde7644122eeae6c444e3520f66ab1546ba7fdf6
2021-07-09 18:25:57 +01:00