The test in packages/apps/Settings/tests/unit/src/com/android/settings/
wifi/WifiSettingsUiTest.java fails because the TestAccessPointBuilder
class and all methods in it seem to get stripped during build time
since they aren't referenced by code within the settings app itself.
Bug: 33245941
Test: runtest --path packages/apps/Settings/tests/unit/src/com/android/settings/wifi/WifiSettingsUiTest.java
Change-Id: I22b7e9fa54fcd67e0f754aca47907d87db9d7056
Merged-In: I92b56b7908e5be8a3553a2779646d48bb5b94f01
When starting WifiTracker, show whatever results are available from
platform until new scan results come in. This allows us to show the best
available results from the previous location scan. Once we have resumed
scanning and new scan results come in, the previous logic of evicting
scan results older than 15 seconds applies.
Also prevent unnecessary onConnectedChanged callbacks from being fired,
which may unnecessarily cause UI reloading bars to appear by performing
unnecessary work.
Bug: b/38212080
Test: runtest --path
frameworks/base/packages/SettingsLib/tests/integ/src/com/android/settingslib/wifi/AccessPointTest.java &&
runtest --path
frameworks/base/packages/SettingsLib/tests/integ/src/com/android/settingslib/wifi/WifiTrackerTest.java
Change-Id: I3db9d98425b3d2fc66fa0757807a318d0c7456ee
The external settings api needs to pass icons for
corresponding settings. The following signals didn't have
icons in Settings.
- Night display
- Location
Bug: 62706782
Test: make RunSettingsGoogleRoboTests
Change-Id: Ia2feaa9cfea7dbce165545e5b7d96ad0798b8e07
We store a index value in shared pref to figure out when a suggestion
should be displayed next time. However the rule can change due to
various reasons. When the index and the rule itself go out of sync, we
should not crash.
Merged-In: Id3ea88b6d321434e20ac0cd3e2670524c237e24e
Change-Id: Ied4a0359f9bc22ee94ec79c0591d2671a9c31b86
Fix: 63908636
Test: robotests
This stops the RSSI of an AccessPoint object being updated from WifiInfo
for the current network, when that WifiInfo does not have a valid RSSI.
This occurs when attempting to connect to a network, and the connection
has not yet been established.
Fixes a UI bug where the signal strength would appear to be zero when
attempting to connect to something, or after failing to.
Bug: 63487286
Test: runtest --path
frameworks/base/packages/SettingsLib/tests/integ/src/com/android/settingslib/wifi/AccessPointTest.java
Test: Manual. Attempt to connect to network with bad PSK. Observe Signal
strength does not get set to zero.
Change-Id: Ia5343fb6f0935134e6a4f82034de164342fe55d4
This allows us to properly use it in Robolectric tests.
Bug: 63154615
Test: Used in Settings unit test
Change-Id: I9f55529449313003a5ed10a997e21591ceae43cb
task.
In Settings, after calling ProfileSelectDialog and choosing a profile,
then going back would go 2 activities back. The issue is that
ProfileSelectDialog was calling finish() in the no-longer-used
SettingsDrawerActivity. This caused the any activity calling the
dialog to be removed from the task, and thus being impossible to
go back to. This call to the drawer is also a code smell.
Bug: 36237246
Fixes: 36237246
Test: NA
Change-Id: I6f309b220ffae1d86e6879ddf6a0305ad3dde3e8
(cherry picked from commit b975c0e44445f76d67e7576c1e8e08609b696408)
Change the namespace for the icon image view to settings package.
Change-Id: Id1ffbc1742bedab93c9f03e9d464f532fe2c33af
Fix: 63666970
Test: Visual
(cherry picked from commit a990b5da04b4f5d475ff038f99d7dd908e931d63)
Since setup wizard is distributed by binary, and internal framework
resource IDs may shift due to OEM customizations, load the resource
via its name instead.
Long term SUW should move away from depeneding on framework internal
resources or be open sourced.
Test: Existing tests pass
Bug: 63546650
Change-Id: I3555945d1f310ee79bdfc3542411d46a4fd4bf7d
In ag/2409026 we introduced a stale scan result bit to prevent callbacks
from sticky broadcasts from occuring until we have fetched the latest
set of scan results. However, this initial value was set to false hence
there is a race condition in which the currently connected network can
still be shown without any other networks, as the scan results have not
yet been processed.
By changing the initial value to true, we address this race condition.
Bug: b/62493360
Test: runtest --path
frameworks/base/packages/SettingsLib/tests/integ/src/com/android/settingslib/wifi/WifiTrackerTest.java
Change-Id: I5f2108e17d2c549e2176ccf64e640fbd4808b5f1
Forgetting a network from the wifi network details page throws an NPE in
WifiSettings when the details fragment exits, crashing the app.
Bug: b/63351286
Test: runtest --path
frameworks/base/packages/SettingsLib/tests/integ/src/com/android/settingslib/wifi/AccessPointTest.java
Change-Id: I749ecbda5654ff7a86ffe4c38ca74ebe338923f0
* Add handler for BluetoothDevice.ACTION_BATTERY_LEVEL_CHANGED intent
* Check battery level information when UI is updated
* Show battery level in Quick Settings connected device summary line
* Show battery level in Bluetooth Settings connected device summary line
* Show battery level in Bluetooth device details page device summary
line
* Add unit test for CachedBluetoothDevice, change HeadsetProfile and
HidProfile to not final to enable mocking
Bug: 35874078
Test: make, unit test, connect to remote devices, connect/disconnect
profiles
Change-Id: I729048cace73aab29337a8002a2897d2acf22fa6
It wasn't creating a delta so as soon as a change happened, it would
return true for any config changes.
Also StatusBar wasn't receiving config changes because the callback
was named wrong and SystemBars no longer passes it through.
Test: manual
Fixes: 62968485
Fixes: 62893293
Change-Id: I56750047168007edd0ca9ea35cb36c23dc790661
In app tests (as opposed to RoboTests), we don't have a shadow
BluetoothSettings class and can't mock it because it's final, but we
need a way to mock out the address of a CachedBluetoothDevice. So this
adds a convenience method on CachedBluetoothDevice that can be mocked.
Bug: 62447414
Test: (should be covered by other tests)
Change-Id: If818d3dcc783b4aa03f7c6d7c441ba44ea980ab7
This allows it to be reused in the SavedAccessPointsWifiSettings.
Bug: b/62374459
Test: make -j40 RunSettingsLibRoboTests
Change-Id: Id137f56ceafe461d217c0eee6b571ccfa4eaff1f
This is necessary to make it accessible to other test packages, such as
WifiSettingsUiTest.java in packages/apps/Settings.
Bug: 37558394
Test: runtest --path
packages/apps/Settings/tests/unit/src/com/android/settings/wifi/WifiSettingsUiTest.java
Change-Id: Ic1e4185639b2947433d6371e74448097d6adb962