Commit Graph

14 Commits

Author SHA1 Message Date
Lifu Tang
caa1b51ef2 Revert "Remove duplicate strings."
Revert submission 19748582-settings_yesno

Reason for revert: Common strings in English could be translated into different strings in other languages.

Reverted changes: /q/submissionid:19748582-settings_yesno

Bug: 272603842
Test: build and open Settings app
Test: atest SettingsRoboTests
Change-Id: Iaad301c5513478fb95e40987ea3ccb4f923d71fa
2023-03-15 22:39:24 +00:00
Kweku Adams
5949fccc7a Remove duplicate strings.
"Yes" and "no" were redefined many times with no clear benefit, so this
consolidates them into one definition.

Bug: 243843096
Test: Build, install, and open the Settings app
Test: atest SettingsRoboTests
Change-Id: I5f84d09f223efd478461ded93aeac82bf7b128d8
2022-08-26 00:07:08 +00: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
Tsung-Mao Fang
8498760b07 Ignore broken tests related to wifi tracker lib
Test: Run entire robo tests
Bug: 214938188
Change-Id: Ic23c758737786c2294c400fd2746583fef426f2f
2022-01-17 21:27:25 +08:00
Weng Su
029e2d771e Fix WiFi show "Not connected" always issue
- The WiFi summary is designed to be changed when the
onCapabilitiesChanged() callback is made from the ConnectivityManager,
but there is no guarantee that there will be a callback after the
settings are registered to the ConnectivityManager.

- Need to fatch initial state information to show the correct summary
first when the settings register callback to the ConnectivityManager.

- Screenshot:
  https://screenshot.googleplex.com/AwmLX2ZQE2grC7N

Bug: 179335681
Test: manual test
- make RunSettingsRoboTests ROBOTEST_FILTER=WifiSummaryUpdaterTest

Change-Id: Ib5d22bdf34a3832dd5082e6e11cee699694afdee
2021-02-08 23:15:14 +08:00
James Lemieux
f1dade40d2 Use binary resource support in robolectric
The resources available to tests are now exactly the merged resources
located in the APK under test.

Bug: 74359828
Test: make -j56 RunSettingsRoboTests
Change-Id: I050db81a92decefea23314b5ec7a62f77ff4bb2b
2018-12-12 19:53:49 -08:00
Fan Zhang
23f8d59d02 Sort imports
Having consistent import order will reduce chance of merge
conflict between internal and external master

Test: rebuild
Change-Id: I0b1a170967ddcce7f388603fd521f6ed1eeba30b
2018-08-28 22:13:15 +00:00
Amin Shaikh
c685d0fe9b Show wifi status label in preference summary.
Bug: 74075761
Test: m RunSettingsRoboTests && manual
Change-Id: I286fac5d9390634facc0f04b845ef668c55d1331
2018-03-26 14:37:09 -04:00
James Lemieux
22a39c2b93 Use external/robolectric-shadows/run_robotests.mk
This allows Settings to test against the latest framework changes.

Also replaced TestConfig with traditional robolectric.properties.

Bug: 73173204
Bug: 73892008
Test: make -j56 RunSettingsRoboTests
Change-Id: I3135b4fa5f095ba79b282a76f45dd9baa2584bc7
2018-03-04 03:50:08 -08:00
jeffreyhuang
cbfb099a40 Rename SDK_VERSION_O to SDK_VERSION
Test: make RunSettingsRoboTests -j40
Change-Id: I6715062d8addadda441e32809db1af55f15e3a90
2017-12-05 16:43:54 -08:00
jeffreyhuang
71cf59e62f Move wifi test package to sdk 26
Test: make RunSettingsRoboTests -j40
Change-Id: I9ef0979a7c6c3647cedd48a2c6ab855928c1b57e
2017-12-04 16:18:55 -08:00
Andrew Sapperstein
9f1e911759 Refactor test runner to use static list of resource paths
Previously everything lived in an inner class method of
SettingsRobolectricTestRunner. That method has now been turned into
a static method so that it can be called by other runners.

Bug: 62460102
Test: robotests
Change-Id: I6612b1f26404587301c534c8ba60e39d59d6c840
2017-06-09 09:21:26 -07:00
Doris Ling
5853f9742f Update Wifi off summary text.
Changed the test from "disabled" to off when wifi is turned off.

Fix: 36296257
Test: make RunSettingsRoboTests
Change-Id: Iae421c15b812fa7a5c3ec841e9d2c28d21063884
2017-04-03 11:40:23 -07:00
Doris Ling
c4c9f4d50e Update Network & internet->Wi-Fi to use MasterSwitchPreference.
- Add a preference controller for Network & internet->Wi-Fi to control
  the preference toggling and summary update.
- Refactor WifiSettings and WifiEnabler to share code between the new
  wifi preference controller and the wifi setting.
- Refactor BluetoothSummaryHelper to have a common base class with the
  WifiSummaryHelper.
- Rename the summary helper to summary updater.

Bug: 34280769
Test: make RunSettingsRoboTests
Change-Id: I00ebfc161bcef89331bb41ba405ed8cb8232d248
2017-01-25 10:43:01 -08:00