Commit Graph

15813 Commits

Author SHA1 Message Date
Yuri Lin
e6e5847cce Rename Do Not Disturb -> Priority Mode
in strings only -- no UI changes in this CL.

Bug: 190180868
Test: manual, ZenModeBypassingAppsPreferenceControllerTest (robotest)

Change-Id: I7bb74d2fd1a9d3b24a8b81a6cc8ba35d38b25656
2022-01-24 14:41:21 -05:00
Lais Andrade
dbcdd2bf46 Add VibrationPreferenceControler to check availability
Add check to Vibrator.hasVibrator() to the "Vibration & haptics"
settings page.

Bug: 178530831
Test: VibrationPreferenceControllerTest
Change-Id: Ia574d59ad086dd273a9a4ca9d3b472bf23e3684a
2022-01-24 15:45:13 +00:00
Jan Tomljanovic
1e81c40558 Merge "Call system service API instead of checking the phenotype flag directly." 2022-01-24 12:55:20 +00:00
Lais Andrade
76b2cd60e5 Disable ring, notification and touch vibration in silent mode
Disable haptic settings for ring, notification and touch feedback when
the phone ringer mode is set to silent.

Preserve the setting values and display message explaining why those
settings are disabled.

Bug: 203188852
Test: *Vibration[Intensity|Toggle]PreferenceControllerTest
Change-Id: I6c24079ece9d637f2feb487f756937888a92caa7
2022-01-24 11:01:08 +00:00
TreeHugger Robot
3b362e84f4 Merge "Fix SliceContextualCardRendererTest" 2022-01-24 10:34:56 +00:00
TreeHugger Robot
cf5edf2cc1 Merge "Fix ContextualCardsFragment test failure" 2022-01-24 10:19:53 +00:00
TreeHugger Robot
544397015b Merge "Fix WifiSummaryUpdaterTest issues for registerReceiver security design" 2022-01-24 09:46:33 +00:00
Yi-Ling Chuang
85356adb94 Fix EligibleCardChecker test failure
Use a fake slice instead of a wifi slice to decouple the dependency.

Fixes: 215046603
Test: robotest
Change-Id: I02da766007c5bb096dc0844f9ea62d0b49e1f4d6
2022-01-24 15:59:57 +08:00
Yi-Ling Chuang
beb88dc4a9 Fix SliceContextualCardRendererTest
Fixes: 215046609
Test: robotest
Change-Id: I6b48d3b0739fe64a2380426efa03acd1971cd6b1
2022-01-24 14:04:01 +08:00
Yi-Ling Chuang
62b1f71402 Fix ContextualCardsFragment test failure
Fixes: 215046286
Test: robotest
Change-Id: I930c3009891512011974aa399b9a4034d33243e5
2022-01-24 13:55:19 +08:00
Stanley Wang
d329f3d79c Ignore tests to avoid Settings presubmit test failure.
Bug: 216036457
Test: run robo test
Change-Id: I4ec2f2f9a25e7212ac65710e88541661cd59d461
2022-01-24 12:58:31 +08:00
TreeHugger Robot
53efa5be66 Merge "Mock WifiP2pManager.class for WifiP2pSettingsTest" 2022-01-24 02:49:09 +00:00
Menghan Li
109e73a844 Merge "Utils to operate tooltips widget for QS panel" 2022-01-24 02:10:49 +00:00
menghanli
db8f2a4004 Utils to operate tooltips widget for QS panel
Bug: 210356011
Test: make RunSettingsRoboTests ROBOTEST_FILTER=AccessibilityQuickSettingUtilsTest
Change-Id: Ia743be8350e6a84cbe44827fb2d6f44f1f04e426
2022-01-24 08:10:43 +08:00
Weng Su
679153be09 Mock WifiP2pManager.class for WifiP2pSettingsTest
Bug: 214938188
Test: manual test
make RunSettingsRoboTests ROBOTEST_FILTER=WifiP2pSettingsTest

Change-Id: I21bfc1c8303970437ae2641ed0f2f9c16f09b33f
2022-01-23 10:15:40 +00:00
ykhung
c8a63b3416 Fix broken tests: com.android.settings.fuelgauge
Bug: 215064709
Fixes: 215064709
Test: make -j64 RunSettingsRoboTests ROBOTEST_FILTER="com.android.settings.fuelgauge"
Change-Id: I79a27b4fcef3a21207b37db422d983ae9d521b45
2022-01-23 16:28:31 +08:00
Weng Su
481f696a88 Fix WifiSummaryUpdaterTest issues for registerReceiver security design
- Security team add new interface to Context.registerReceiver() with a
third parameter for new security design.

- The new interface might have some issues in the test environment.

- Spy the registerReceiver() and unregisterReceiver() to avoid
unexpected issues.

Bug: 214938188
Test: manual test
make RunSettingsRoboTests ROBOTEST_FILTER=WifiSummaryUpdaterTest

Change-Id: Ibd1c5c1f7b4309ad5079f33bb232f249c6bd997f
2022-01-22 14:40:34 +00:00
Weng Su
a9a1bb3747 Mock UserManager.class for WifiSettingsTest
Bug: 214938188
Test: manual test
make RunSettingsRoboTests ROBOTEST_FILTER=WifiSettingsTest

Change-Id: I1b8faba6348b6dfddbd7eb6ccfaa35ca32366c91
2022-01-22 14:07:40 +00:00
TreeHugger Robot
7dd97c7091 Merge "Mock WifiManager.class for HotspotConditionControllerTest" 2022-01-22 08:35:50 +00:00
TreeHugger Robot
4cdf2aa472 Merge "Mock WifiManager.class for Roboletric test-cases" 2022-01-22 08:33:58 +00:00
TreeHugger Robot
3654b61ebd Merge "Mock WifiPickerTracker.class for Roboletric test-cases" 2022-01-22 08:29:28 +00:00
Menghan Li
386206051d Merge "Allow users dismiss accessibility quick settings tooltips when clicked" 2022-01-22 02:25:01 +00:00
Yasin Kilicdere
031104f18e Merge "Make sure activity for adding a supervised user is opened full screen." 2022-01-21 18:16:48 +00:00
Lucas Silva
b92fa1fdaa Fix broken DreamPickerControllerTest
The dream infos are cached at the time the controller is created, so
ensure that we mock out the dream infos before building the controller
instance.

Test: make -j64 RunSettingsRoboTests ROBOTEST_FILTER="com.android.settings.dream.DreamPickerControllerTest"
Bug: 215660413
Change-Id: Ie86f701a46dfc9a0ef185459a1dbf9016c1194fc
2022-01-21 15:50:49 +00:00
Weng Su
c70c0f255a Merge "Mock WifiP2pManager.class for ResetNetworkConfirmTest" 2022-01-21 14:07:02 +00:00
TreeHugger Robot
54dbe403eb Merge "New UX for the NFC default payment settings" 2022-01-21 12:30:06 +00:00
TreeHugger Robot
54769b55ca Merge "Ignore tests to avoid Settings presubmit test failure." 2022-01-21 11:45:36 +00:00
Jack Yu
9de30f08e6 New UX for the NFC default payment settings
Re-design the UX.

Bug: 202367033
Test: maunal
      make RunSettingsRoboTests ROBOTEST_FILTER=NfcForegroundPreferenceControllerTest
      make RunSettingsRoboTests ROBOTEST_FILTER=PaymentSettingsTest
Change-Id: I4c05ac4a1974645c76a37900d64aa8e1a491bca1
2022-01-21 10:25:09 +00:00
Stanley Wang
cee6346ce9 Ignore tests to avoid Settings presubmit test failure.
Bug: 215660413
Test: run robo test
Change-Id: I9cb04f5fee9463d40954509c087eb428f16e3b68
2022-01-21 17:57:53 +08:00
Weng Su
781ea4c6ab Mock WifiP2pManager.class for ResetNetworkConfirmTest
Bug: 214906101
Test: manual test
make RunSettingsRoboTests ROBOTEST_FILTER=ResetNetworkConfirmTest

Change-Id: I3aa22c06fc8fcd22deb8b15b2998539b48d3ce39
2022-01-21 09:41:01 +00:00
menghanli
238639c494 Allow users dismiss accessibility quick settings tooltips when clicked
Problem: When Talkback on, users cannot use double tap or swipe to move focus on the next window.
Solution: Talkback speaks out "double tap to dismiss" to allow dismissing this tooltips.

Bug: 215656141
Test: make RunSettingsRoboTests ROBOTEST_FILTER=AccessibilityQuickSettingsTooltipWindowTest
Change-Id: I8f7066a805ec963f9f0f8fee1b81ad008418c4a6
2022-01-21 17:16:10 +08:00
Daniel Huang
56a62d74ec Merge "[Panlingual] Suggested locales update" 2022-01-21 09:12:06 +00:00
Tom Hsu
456eaedbcd Merge "[Panlingual] Adds a filter of application for per apps locale change." 2022-01-21 09:02:40 +00:00
Weng Su
c735f98943 Mock WifiManager.class for HotspotConditionControllerTest
Bug: 215047177
Test: manual test
make RunSettingsRoboTests ROBOTEST_FILTER=HotspotConditionControllerTest

Change-Id: I902383f935d38b1736e5cced388a8b164a428007
2022-01-21 08:22:59 +00:00
Weng Su
ea0425e1f8 Mock WifiPickerTracker.class for Roboletric test-cases
Bug: 214938188
Test: manual test
make RunSettingsRoboTests ROBOTEST_FILTER=NetworkRequestDialogActivityTest
make RunSettingsRoboTests ROBOTEST_FILTER=NetworkRequestDialogFragmentTest
make RunSettingsRoboTests ROBOTEST_FILTER=NetworkRequestErrorDialogFragmentTest
make RunSettingsRoboTests ROBOTEST_FILTER=WifiConnectionPreferenceControllerTest

Change-Id: I4c15c2a095203338bb9cf7bcd359242d59bf8b4e
2022-01-21 07:24:21 +00:00
Weng Su
64cc3bf9a4 Mock WifiManager.class for Roboletric test-cases
Bug: 214938188
Test: manual test
make RunSettingsRoboTests ROBOTEST_FILTER=AddNetworkFragmentTest
make RunSettingsRoboTests ROBOTEST_FILTER=ConfigureWifiEntryFragmentTest
make RunSettingsRoboTests ROBOTEST_FILTER=ContextualWifiSliceTest
make RunSettingsRoboTests ROBOTEST_FILTER=WifiConfigControllerTest
make RunSettingsRoboTests ROBOTEST_FILTER=WifiSliceTest

Change-Id: I96873c48b36ed11b30e32bba1b98b6328ad17bb7
2022-01-21 07:17:37 +00:00
TreeHugger Robot
adf5ccf359 Merge "Fix broken test" 2022-01-21 03:50:49 +00:00
TreeHugger Robot
f85ec568e5 Merge "Resolve test failure in WorkModePreferenceControllerTest" 2022-01-21 02:51:27 +00:00
Kate Montgomery
d6909d1843 Merge "Make the show/hide system setting for recent location acccesses sticky." 2022-01-21 00:35:55 +00:00
Lifu Tang
885dff9b9a Fix broken test
Bug: 215047319
Test: run test case `LocationInjectedServicesPreferenceControllerTest`
Change-Id: I446f1341042d69ea6657d2f4bf1fbbac48961a4f
2022-01-20 14:23:16 -08:00
Kate Montgomery
14e6c73687 Make the show/hide system setting for recent location acccesses sticky.
This is in order to align the location indicator with the list of recent
accesses shown in Settings.

Bug: 191503437
Test: manual
Change-Id: I7aaa65390567ca644e7137de15c558cdcdb29935
2022-01-20 21:19:44 +00:00
Michael Groover
a0dc31f3c5 Resolve test failure in WorkModePreferenceControllerTest
Android T introduced a new requirement that apps registering for
non-system broadcasts via Context#registerReceiver must specify a flag
indicating whether the receiver should be exported. This flag was
added to the receiver in WorkModePreferenceController, but this broke
a test since the signature of the registerReceiver method was changed.
This commit updates the signature of the method in the test to also
expect an int parameter for the flags.

Fixes: 214906107
Test: make RunSettingsRoboTests ROBOTEST_FILTER=WorkModePreferenceControllerTest
Change-Id: I17061ab24ed3ec3def4062fe461803ad88bce9c8
2022-01-20 11:45:43 -08:00
danielwbhuang
714bcfff2c [Panlingual] Suggested locales update
1. Extract the Country from the Top system langauge, TelephonyManager.getSimCountryIso().toUpperCase(Locale.US), and TelephonyManager.getNetworkCountryIso().toUpperCase(Locale.US).
2. For each app-supported locale, if the region is identical then add this as a suggested language.

Bug: 209729740
Test: atest AppLocaleDetailsTest
Change-Id: I4f95a638916e88197fc37546c7786c63b59f581d
2022-01-20 22:48:28 +08:00
Daniel Hsieh
32420a07db Merge "Refactor SettingsContentObserver and add it to follow typing feature." 2022-01-20 11:51:21 +00:00
TreeHugger Robot
8662e4642e Merge "Fix search test" 2022-01-20 09:58:03 +00:00
Tsung-Mao Fang
8b0e4018e1 Fix search test
The broken test is because the activityInfo has no package name.
Set a random package name to fix it.

Test: run robo test
Fix: 214945263
Change-Id: I5ae5a0021f1473e6eadbad5f6e1f22840a44d592
2022-01-20 09:57:34 +00:00
Yuri Ufimtsev
a031404afc Merge "Change the default Controller keys for RoboTests" 2022-01-20 09:05:51 +00:00
Daniel Hsieh
55bc49860b Refactor SettingsContentObserver and add it to follow typing feature.
Refactor SettingsContentObserver and rename it to
AccessibilitySettingsContentObserver. Besides, we register it to observe
follow typing feature preference value.

The reasons behind refactor:
1. We change callback signature due to the consistency for register it
by preference key, not by Uri.
2. We refactor the default preference key to a seperate method. Since
the default value is related to accessibility, we rename it with
accessibility prefix.
3. We can register different callback for difference collections of
preference keys.

Default preference keys: They existed in the previous constructor.
1. Settings.Secure.ACCESSIBILITY_ENABLED
2. Settings.Secure.ENABLED_ACCESSIBILITY_SERVICES

Bug: 194668976
Test: make RunSettingsRoboTests ROBOTEST_FILTER=
           AccessibilitySettingsTest
           AccessibilitySettingsContentObserverTest
           AccessibilityShortcutPreferenceFragmentTest
           MagnificationFollowTypingPreferenceControllerTest
           ToggleFeaturePreferenceFragmentTest
           ToggleScreenMagnificationPreferenceFragmentTest
Change-Id: Iafd27e044ebe2536ae7ae55c1c80af54f7f0f822
2022-01-20 08:38:27 +00:00
Allen Su
2e9760efd1 Merge "Change locale comparison API" 2022-01-20 06:52:28 +00:00
TreeHugger Robot
e0f8b565e1 Merge "Add "Reboot with MTE" option for supported devices." 2022-01-20 06:30:16 +00:00