The following changes in UserManager are required for ongoing
improvements to CTS/GTS infrastructure.
- Exposed the following as testAPIs:
* isGuestUserEphemeral
* createUser
* preCreateUser
* createProfileForUser
* createRestrictedProfile
* getUsers
* getUserType
- Added permissions to the following APIs:
* CREATE_USERS for getUserName
* INTERACT_ACROSS_USERS for getProfileParent
- Added CREATE_USERS permission to the documentation of
getUsers and the APIs that call it.
Test: Confirmed that a CTS test can call these APIs
Bug: 178695365
Change-Id: Id9105db3bfefb926139715b728acedefd2a5ca3e
Creates presubmit test mapping for BatteryStats-related
files.
These tests can be run manually via
atest FrameworksServicesTests:com.android.server.am.BatteryExternalStatsWorkerTest FrameworksServicesTests:com.android.server.am.MeasuredEnergySnapshotTest FrameworksServicesTests:com.android.server.am.BatteryStatsServiceTest FrameworksCoreTests:com.android.internal.os.BatteryStatsTests
Tests that currently fail are marked to be skipped;
they should be addressed by b/180015146.
This is accomplished by introducing a new annotation, @SkipPresubmit.
Test: treehugger presubmit
Bug: 180016384
Change-Id: If01beaa342468aeded660e5766a14391d3ee9bcc
Add information about value returned by Vibrator.getId, including a
description of what the default -1 value represents.
Fix description of CombinedVibrationEffect arguments to
VibratorManager methods.
Fix: 180962151
Fix: 180963421
Test: N/A
Change-Id: I3fab2d5fe299be5a951f32bd75eb2e5275ef6e56
Previously, regardless of the downloading progress reported by the client,
right before installation completion, we publish the install progress
as 0.9. For incremental installs, because we will publish the
incremnetal loading progress after the installation completion, we
might see the progress going backward, because the incremental loading
progress is likely less than 0.9.
For a smoother transition, we do not overwrite the client progress.
Instead, during committing, publish the incremental loading progress
while making sure the progress doesn't go backwards. After committing,
the launcher will keep showing the incremental loading progress.
+ Making sure the installer's incremental progress listener is
unregistered after session is committed.
See the demo video for an example. Notice that the progress is changed
during "Installing..." (around 00:35).
BUG: 180040329
Test: manual
Change-Id: I6c30b0dac6758fd103ed6a985ca39b6f8557ba8f
Also, combine WifePowerCalculator and WifiPowerEstimator: they
have a lot more in common than different.
Bug: 158137862
Test: atest WifiPowerCalculatorTest
Change-Id: Ib937102043a1fe04941ecfd09b5077b14058e6ef
... because it is more tied to Context instance that developers
are working with.
Bug: 179308116
Test: atest ContextIsUiContextTest
Change-Id: I41d90c4b5b81b430fc8007a0bdf86c6fd1c54400
Scaling down low amplitudes can lead to one-shot effects with amplitude
zero, which leads to an invalid VibrationEffect and causes
IllegalArgumentException to be thrown on an originally valid effect.
Bug: 179674498
Test: VibrationEffectTest
Change-Id: Ie653084d37f9bfed20aac25f8805ffdf40661e03
* changes:
[IT06]Move INetworkActivityListener into connectivity module
[IT05] Remove the unused network activity logic out from NMS
[IT4.7] Add network activity info into dumpsys for debugging
[IT4.6] Unbundle NMS out from ConnectivityManager
[IT4.5] Update radio power from CS directly
If the device doesn't have a pin, the current RoR preparation will
go through; but the lskf capture event won't happen. In order not
to confuse the caller, throw an exception instead in the no-pin
case.
Bug: 170664917
Test: remove pin, request RoR with adb shell
Change-Id: Ib04c629234b71e3f6cb36bdfe47759a715a69146
- Expand BugreportManager class javadoc
- Explain what "privileged" means
- Highlight only one-BR-at-a-time behavior
- Add more detail to BugreportCallback javadocs
- Explain standard callback invocation flow
- More detail on when BUGREPORT_ERROR_INVALID_INPUT is used
- Add @WorkerThread to {start{,Connectivity},cancel}Bugreport
Bug: 180015324
Test: make
Change-Id: Id3400b1cdd271f47bdeaf8cdc1a0dea61aafc933
There's no reason for getPowerSaveModeTrigger to require the POWER_SAVER
permission. The API is only marked as a SystemApi because it was designed
for a specific use case and 3rd party apps don't need to know the
information, but there's no problem if they get the value. All the value
tells you is whether the device will turn on battery saver automatically
based on the percentage level or if it'll turn on automatically based on
a different dynamic signal.
Bug: 174241855
Test: atest android.os.cts.PowerManagerTest
Test: atest android.permission.cts.PowerManagerServicePermissionTest
Test: atest CtsPermission2TestCases
Test: atest SettingsProviderTest
Change-Id: I3146a681d9c5da9c68a7e6b38b50314b293dc924
This change enforces that only system, root or shell may call
getAllPackages(), a hidden API that shares all package names regardless
of user, instant app or package visibility rules.
The only exception is the uid of iorapd. iorapd needs the package info
to prefetch the right data.
Bug: 179618216
Bug: 174661955
Test: run iorapd and check it works well.
Change-Id: I77460ae19a4d41151577646441f11e2eddbb741a
Merged-In: I77460ae19a4d41151577646441f11e2eddbb741a
(cherry picked from commit 8124efd57b)
INetworkActivityListener is hidden and the only usage is inside
the connectivity module. Thus, move this into module scope.
Bug: 170598012
Test: atest FrameworksNetTests
Change-Id: I0a75c440c1daa773217bbd362b212fda4d07ec64
The network activity logic is moved to ConnectivityService.
CS is no longer setting the idle timer via NMS to netd. The
idle timer should only set from CS, so remove the network
activity logic out from NMS.
Bug: 170598012
Test: atest FrameworksNetTests
Change-Id: Ief9e892586aaee8e9542b9313088fa50d1d411e5
This reverts commit 5f47bc6ba1.
Reason for revert: We still need part of this CL that starts monitoring progress on storage creation. This helps detect the kernel selinux issue where the security context of a file was assigned wrongly.
BUG: 180514262
Test: builds
Change-Id: I33fca8f9be27f3f2dfab089feaf3c241ae7d5d49