summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorRoshan Pius <rpius@google.com>2019-07-03 16:23:50 -0700
committerandroid-build-merger <android-build-merger@google.com>2019-07-03 16:23:50 -0700
commita8153646b0c113f2cb5bcc1c565e9998c4f125f2 (patch)
tree67f55b5cec0f9a6c15ce2468bde4e83895cfab3c /tests
parent4a900f532c60f039103ac32320b63c18fd98741e (diff)
parent7abed5d4cf741aca02836d06664263dc1e3aa699 (diff)
WifiNetworkSuggestionsManager: Persist user approval immediately
am: 7abed5d4cf Change-Id: I54c3c9e22353d89f4f0d3dbc956ddca302ef13f5
Diffstat (limited to 'tests')
-rw-r--r--tests/wifitests/src/com/android/server/wifi/WifiNetworkSuggestionsManagerTest.java8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/wifitests/src/com/android/server/wifi/WifiNetworkSuggestionsManagerTest.java b/tests/wifitests/src/com/android/server/wifi/WifiNetworkSuggestionsManagerTest.java
index 98e5178d7..8d33fae36 100644
--- a/tests/wifitests/src/com/android/server/wifi/WifiNetworkSuggestionsManagerTest.java
+++ b/tests/wifitests/src/com/android/server/wifi/WifiNetworkSuggestionsManagerTest.java
@@ -1870,6 +1870,10 @@ public class WifiNetworkSuggestionsManagerTest {
// Cancel the notification.
verify(mNotificationManger).cancel(SystemMessage.NOTE_NETWORK_SUGGESTION_AVAILABLE);
+ // Verify config store interactions.
+ verify(mWifiConfigManager, times(2)).saveToStore(true);
+ assertTrue(mDataSource.hasNewDataToSerialize());
+
reset(mNotificationManger);
// We should not resend the notification next time the network is found in scan results.
mWifiNetworkSuggestionsManager.getNetworkSuggestionsForScanDetail(
@@ -1911,6 +1915,10 @@ public class WifiNetworkSuggestionsManagerTest {
// Cancel the notification.
verify(mNotificationManger).cancel(SystemMessage.NOTE_NETWORK_SUGGESTION_AVAILABLE);
+ // Verify config store interactions.
+ verify(mWifiConfigManager, times(2)).saveToStore(true);
+ assertTrue(mDataSource.hasNewDataToSerialize());
+
reset(mNotificationManger);
// Now trigger the app-ops callback to ensure we remove all of their suggestions.