summaryrefslogtreecommitdiffstats
path: root/packages/SystemUI/tests/src
diff options
context:
space:
mode:
Diffstat (limited to 'packages/SystemUI/tests/src')
-rw-r--r--packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerSignalTest.java14
1 files changed, 12 insertions, 2 deletions
diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerSignalTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerSignalTest.java
index 52dea40..d9b9063 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerSignalTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerSignalTest.java
@@ -21,6 +21,7 @@ import android.content.Intent;
import android.net.ConnectivityManager;
import android.net.NetworkCapabilities;
import android.os.Looper;
+import android.telephony.ServiceState;
import android.telephony.SignalStrength;
import android.telephony.SubscriptionInfo;
import android.telephony.TelephonyManager;
@@ -70,11 +71,20 @@ public class NetworkControllerSignalTest extends NetworkControllerBaseTest {
public void testEmergencyOnlyNoSubscriptions() {
setupDefaultSignal();
+ setSubscriptions();
+ mNetworkController.mLastServiceState = new ServiceState();
+ mNetworkController.mLastServiceState.setEmergencyOnly(true);
mNetworkController.recalculateEmergency();
- verifyEmergencyOnly(false);
+ verifyEmergencyOnly(true);
+ }
+ public void testNoEmengencyNoSubscriptions() {
+ setupDefaultSignal();
setSubscriptions();
- verifyEmergencyOnly(true);
+ mNetworkController.mLastServiceState = new ServiceState();
+ mNetworkController.mLastServiceState.setEmergencyOnly(false);
+ mNetworkController.recalculateEmergency();
+ verifyEmergencyOnly(false);
}
public void testNoSimlessIconWithoutMobile() {