Commit Graph

15703 Commits

Author SHA1 Message Date
Derek Jedral
9c67ee1eb1 Merge "Remove feature flag for active unlock" into udc-dev 2023-05-09 17:17:11 +00:00
Vincent Wang
5801e98d7f Merge "Test Fix SettingRobolectricTest Fail" into udc-dev 2023-05-09 09:50:50 +00:00
Vincent Wang
818f77cd1f Test Fix SettingRobolectricTest Fail
Bug: b/275023433
Test: NA
Change-Id: If2dcb8f6c196327129ccc9375b190e394c994efa
2023-05-09 06:26:39 +00:00
Sunny Shao
aeb42d1438 Fix the UI in the left side & right side inconsistent problem
- Let the homepage show "Network & Internet" item in demo mode on large screen device.

Fixes: 276157240
Test: atest TopLevelNetworkEntryPreferenceControllerTest
Change-Id: Ife8bce28e6bc47caf3f06b1027579ea0e52172a3
2023-05-09 09:39:36 +08:00
Derek Jedral
501f3635dc Remove feature flag for active unlock
Active Unlock was guarded behind a feature flag for two main purposes.
1) To select the unlock intent or biometric failure layout. We've
   settled on unlock intent, so we no longer need the biometric failure
   codepath.
2) To guard the feature rollout. However, the additional platform guard
   is not necessary, since this feature availability is still guarded
   based on whether the secure settings are flipped to valid targets.
In order to keep the scope of this CL small, useBiometricFailureLayout
always returns false. Another CL will clean up all areas where it and
useUnlockIntentLayout are referenced.

Test: make RunSettingsRoboTests
Bug: b/280306741
Change-Id: I331afe9654b72249d461007c087e7f81783d7625
2023-05-08 12:46:36 -07:00
Derek Jedral
42deb763e0 Merge "Change preference title if Active Unlock enabled" into udc-dev 2023-05-08 17:56:32 +00:00
Treehugger Robot
fb1cebd7f9 Merge "Fix the updateDialogForCdmaPhone test case failed" into udc-dev 2023-05-08 10:25:06 +00:00
Sunny Shao
b723c4f96a Fix the updateDialogForCdmaPhone test case failed
- This is a side effect of the CL(ag/16379105) which removed the getTextAsDigits API.
- Update the return value as empty string of the TelephonyManager.getImei().

Fixes: 215071948
Test: atest ImeiInfoDialogControllerTest
Change-Id: I790b5dc505ad1a91a951a4c46b241baddea392a1
2023-05-08 14:01:23 +08:00
Jack He
2605ccbcfa Merge changes from topic "LeAudioBeta" into udc-dev
* changes:
  Hide the LE audio toggle by flag
  Add toggle to show/hide the Per Device Enable LE Audio Toggle in Device details
2023-05-06 00:42:40 +00:00
Chaohui Wang
39bf7dd530 Fix dialog leak in RequestPermissionActivity
Dialog still show when activity destroyed will cause leak.

Dismiss dialog when activity onDestroy to fix this issue.

Fix: 279522922
Test: Manually with "Don't keep activities"
Test: Robolectric Test
Change-Id: I445f4b160020823a6f6e2883055218c1224e2c48
2023-05-05 17:30:02 +08:00
Daniel Huang
08b2b68e22 Merge "[Fixed] Reverse scrolling setting is reversed" into udc-dev 2023-05-05 02:33:13 +00:00
Treehugger Robot
54de6fd80b Merge "Support incompatible charger state in the battery main page" into udc-dev 2023-05-04 08:28:57 +00:00
Chaohui Wang
678b1d5fa4 Merge "Fix SettingsDumpServiceTest" into udc-dev 2023-05-04 07:39:14 +00:00
Hao Dong
1c9288fa24 Merge "Call onFaceStrengthChanged() only when authenticators registered." into udc-dev 2023-05-04 07:00:40 +00:00
Hao Dong
6e8434b793 Call onFaceStrengthChanged() only when authenticators registered.
Test: atest FaceEnrollIntroductionTest
Test: manually tested face enroll introduction page
Bug: 280384533
Change-Id: Iac9506d8430459aa399ac8efd3f41cbc6e67260d
Merged-In: Iac9506d8430459aa399ac8efd3f41cbc6e67260d
2023-05-04 06:59:53 +00:00
ykhung
c234196bc1 Support incompatible charger state in the battery main page
https://screenshot.googleplex.com/PrSzAtMAhsyqbsR

Bug: 271775549
Test: make test RunSettingsRoboTests
Change-Id: I0bb912eaab9c8837eaa3a9b998b3ebb5a8e6f99f
2023-05-04 14:57:07 +08:00
Chaohui Wang
e2b9d0680e Fix SettingsDumpServiceTest
SettingsDumpService behavior changed in
Change I9d7fe2e763b9e5840ee76c5eb00bc88288e7ee41

After behavior changed, PrintWriter was wrapped in IndentingPrintWriter,
it's harder to mock the PrintWriter, so check the result directly.

Fix: 280068083
Test: RobolectricTest
Change-Id: I92a7b931c93df4cd9e9c3e47b91a9750df936f15
2023-05-04 14:20:33 +08:00
Treehugger Robot
e71643efac Merge "Fix testNonIndexableKeys_existInXmlLayout" into udc-dev 2023-05-04 03:15:40 +00:00
Derek Jedral
5a75cd54d4 Change preference title if Active Unlock enabled
Change the title of the preference to reflect that Active Unlock can
also be used to unlock the device.

Test: make RunSettingsRoboTests
Bug: b/271782800
Change-Id: Ie227e6dddfc024235fc3568899ef151f14f17696
2023-05-03 12:37:01 -07:00
Patty Huang
f05615f1e8 Add toggle to show/hide the Per Device Enable LE Audio Toggle in Device details
Bug: 280020008
Test: make RunSettingsRoboTests ROBOTEST_FILTER=BluetoothLeAudioDeviceDetailsPreferenceControllerTest
Change-Id: I559f34f2b0764c4f566fe1e0c1357929e2c88fb6
2023-05-04 01:26:15 +08:00
danielwbhuang
0b79c92348 [Fixed] Reverse scrolling setting is reversed
If useTouchpadNaturalScrolling is false, "Reverse scrolling" should be on.

[The API value]
useTouchpadNaturalScrolling: false

[The expected UX behavior]
Reverse scrolling: on
fingers upward, scroll up, content moves down

The description of "useTouchpadNaturalScrolling":
Returns true if moving two fingers upwards on the touchpad should scroll down, which is known as natural scrolling.

The description of "Reverse scrolling":
Content moves up when you scroll down.

Bug: 280047007
Test: manual and passed atest TrackpadReverseScrollingPreferenceControllerTest
Change-Id: Ia5e30fa14b599ddcffae99005114f10412ccad3c
2023-05-03 23:59:55 +08:00
danielwbhuang
bd2d0de0b3 Fix testNonIndexableKeys_existInXmlLayout
This test is for LanguageAndInputSettings UI.
Hence, we should set flag "SETTINGS_NEW_KEYBOARD_UI" to false

Bug: 280018738
Test: make RunSettingsRoboTests -j56 ROBOTEST_FILTER=LanguageAndInputSettingsTest
Change-Id: Ida91a23bb576c81f9618406d54c1d892b23eb4fa
2023-05-03 20:40:53 +08:00
Treehugger Robot
8060347ec6 Merge "Reducing slice requesting logging" into udc-dev 2023-05-03 10:37:24 +00:00
Edgar Wang
fae664c79c Reducing slice requesting logging
Bug: 253684322
Test: rebuild
Change-Id: If0e884875e09bd43b88f6b5f205ad450de488552
2023-05-03 17:04:38 +08:00
Vania Januar
e78b1f377e Merge "Guard against null input device in StylusDeviceUpdater" into udc-dev 2023-05-03 09:00:56 +00:00
Treehugger Robot
d624141732 Merge "Add tests for config check in ClonedAppsPreferenceController" into udc-dev 2023-05-02 14:47:48 +00:00
Ankita Vyas
b32d02c293 Add tests for config check in ClonedAppsPreferenceController
Bug: 280071827
Test: make RunSettingsRoboTests -j56 ROBOTEST_FILTER=ClonedAppsPreferenceControllerTest
Change-Id: Id7c2e73bdb0c2af3e700b3620bde2fe77c47f3e6
2023-05-02 12:03:42 +00:00
Vania Januar
a1af049378 Guard against null input device in StylusDeviceUpdater
Bug: 279170207
Test: StylusDeviceUpdaterTest
Change-Id: Ib4a3f12eaceb87370c800a9dc7eda819c706cd3b
2023-05-02 09:36:43 +00:00
Treehugger Robot
3b60e2a9c3 Merge "Fix battery percentage is inconsistent in settings" into udc-dev 2023-05-02 05:08:39 +00:00
ykhung
0288b6d4af Fix battery percentage is inconsistent in settings
Fix: 275217364
Test: make test RunSettingsRoboTests
Change-Id: I16dd772aacaea3f8ddb6da579adb033124e3dbb7
2023-05-02 11:58:08 +08:00
Edgar Wang
55d7c97022 Merge "Fix test case failed in SystemControlsFragmentTest" into udc-dev 2023-05-02 02:31:02 +00:00
Edgar Wang
10129dc926 Merge "Fix PrivateDnsPreferenceControllerTest test case failed" into udc-dev 2023-05-02 02:30:24 +00:00
ykhung
09c1a4a850 Support incompatible charger state in the Settings main page
https://screenshot.googleplex.com/9af4YCnCCjKHCFY

Bug: 271775549
Test: make test RunSettingsRoboTests
Change-Id: I6562e1b48a85ceceb20389ed87e55e0093040be2
2023-05-02 00:04:01 +08:00
ykhung
a0f3f421dd Fix legacy failed tests to avoid block presubmit
Root cause: the `Robolectric.setupActivity(Activity.class)` is removed from the system, which will always return the null `Context`

Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.fuelgauge.*
Change-Id: Ib52bc715508332bcb4bdcac56ecc414aa43f1419
2023-04-30 00:33:57 +00:00
Treehugger Robot
24666c9737 Merge "Add developer option switch to set ANGLE as the default system driver" into udc-dev 2023-04-29 03:21:56 +00:00
Treehugger Robot
01c585ed27 Merge "Fixes broken Settings test." into udc-dev 2023-04-28 22:37:57 +00:00
Yuxin Hu
25b270c0f8 Add developer option switch to set ANGLE as the default system driver
This change adds a new developer option switch called
"Enable ANGLE". It defaults to off. User can choose
to toggle it on and off, and the value of the system
property "persist.graphics.egl" is changed accordingly:

switch off: persist.graphics.egl=""
switch on: persist.graphics.egl="angle"

When user toggles the switch, a reboot window is
popped up asking user to reboot now to make the change
takes effect. If user chooses to cancel the reboot,
the switch is toggled back. This enforces that a reboot
is required whenever the "persis.graphics.egl" value
changes.

Upon reboot, we will load either ANGLE or native
GLES driver as the system driver, based on the value of
"persist.graphics.egl".

The switch is disabled if ANGLE is not installed
in /vendor partition. We use the system property
"ro.gfx.angle.supported" as an indicator. We set the
two conditions together in angle.mk file. Any device
mk file that inherits angle.mk file will result in
ANGLE libs installed in /vendor and "ro.gfx.angle.supported"
set to true.

Bug: b/270994705
Test: m; flash and check Pixel 7 boots fine
atest SettingsRoboTests:GraphicsDriverEnableAngleAsSystemDriverControllerTest

Change-Id: I565eff614472bb6ba50742e7dfa49b50dca2809f
2023-04-28 18:42:10 +00:00
TreeHugger Robot
6e524f6244 Merge "SettingsRoboTests: fix device state rotation related tests" into udc-dev 2023-04-28 17:01:39 +00:00
Edgar Wang
089e76c429 Fix test case failed in SystemControlsFragmentTest
Fixes: 280071271
Test: local robotest
Change-Id: I96867e9718b4a30289fdcd3fcd9dc70ed8c227b0
2023-04-29 00:42:45 +08:00
Ale Nijamkin
12e05b8c59 Fixes broken Settings test.
In ag/22187500, we added the requirement for a wallpaper picker app to be installed in order to treat the lock screen shortcuts feature as enabled (in addition to the feature flag). That broke this test.

To fix, we're adding a mocked result to the PackageManager to pretend like the wallpaper picker application is installed.

Change-Id: I8654375e3fa33df0984c48fcf91dd8f6c18e984f
Fix: 280017187
Test: the test is back to passing.
2023-04-28 16:22:59 +00:00
Christian Göllner
b613cc4a17 SettingsRoboTests: fix device state rotation related tests
Fixes: 280015539
Test: atest SettingsRoboTests
Change-Id: I0a3cc713f8df0477a172665a60551b456691b17c
2023-04-28 15:26:32 +02:00
Edgar Wang
f411b62425 Fix PrivateDnsPreferenceControllerTest test case failed
- getAvailibilityStatus_availableByDefault()

Fixes: 280048011
Test: locoal robotest
Change-Id: I490dc3348af241a76767885b52238d0b87880532
2023-04-28 21:04:59 +08:00
Chaohui Wang
fec25d4bad Merge "Fix ImeiInfoPreferenceControllerTest" into udc-dev 2023-04-28 11:52:50 +00:00
Treehugger Robot
060a56468d Merge "Revert "Back up the smooth display setting"" into udc-dev 2023-04-28 09:58:16 +00:00
Chaohui Wang
8470122ad1 Fix ImeiInfoPreferenceControllerTest
For test case updatePreference_simSlotWithoutSim_notSetEnabled,
mSecondSimPreference is a mock, instead of check the default value of
isEnabled(), verify it's setEnabled() not called.

Fix: 279880808
Test: RobolectricTest
Change-Id: I72064820754e053def46bdbf10317189c7ac608f
2023-04-28 15:53:44 +08:00
Edgar Wang
8155b72cf8 Merge "Fix test cases failed in WinscopeTraceTest" into udc-dev 2023-04-28 05:28:14 +00:00
TreeHugger Robot
32602794ed Merge "Fixed speed selection lost when changing password in Wi-Fi hotspot settings" into udc-dev 2023-04-27 18:55:20 +00:00
Piotr Wilczyński
eef23f441c Revert "Back up the smooth display setting"
Revert submission 22741921-cherrypick-bug-211737588-lp9s6r5vn3

Reason for revert: b/279215664

Reverted changes: /q/submissionid:22741921-cherrypick-bug-211737588-lp9s6r5vn3

Change-Id: I9b50aa0e2c5a7d328c4aa70b049c37c81e49e89b
Merged-In: I9b50aa0e2c5a7d328c4aa70b049c37c81e49e89b
2023-04-27 16:13:03 +00:00
Edgar Wang
4cf60b02b2 Fix test cases failed in WinscopeTraceTest
Fixes: 276682211
Test: autotest
Change-Id: Id31d5c4e2e1dd61c4af24e042f4aaddee3d33439
2023-04-27 10:22:29 +00:00
Edgar Wang
e0049f0ae8 Merge "Remove restricted icon in SettingsMainSwitchBar" into udc-dev 2023-04-27 08:27:42 +00:00