summaryrefslogtreecommitdiffstats
path: root/packages/SystemUI/tests
diff options
context:
space:
mode:
authorAndrew Flynn <flynn@google.com>2015-06-01 16:34:21 -0400
committerAndrew Flynn <flynn@google.com>2015-06-01 16:45:41 -0400
commit2fdbe128209f02725c645f29bff941efe865da56 (patch)
tree111425300d7e3805712f0326d22297040f2bc663 /packages/SystemUI/tests
parent3b7f9615b70c7e62a018eb1abf0a52c8ba3e4d27 (diff)
downloadframeworks_base-2fdbe128209f02725c645f29bff941efe865da56.zip
frameworks_base-2fdbe128209f02725c645f29bff941efe865da56.tar.gz
frameworks_base-2fdbe128209f02725c645f29bff941efe865da56.tar.bz2
Remove separate light/dark animated vector drawables
Now that AnimatedVectorDrawables can use themed animations, SysUI no longer needs to track separate AVDs for the carrier network change icons. Bug: 21118142 Change-Id: Ifb6d7b5e7e3de85c10bc13183b4142fd2e6714b6
Diffstat (limited to 'packages/SystemUI/tests')
-rw-r--r--packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/CallbackHandlerTest.java13
-rw-r--r--packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerBaseTest.java12
-rw-r--r--packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerSignalTest.java1
3 files changed, 6 insertions, 20 deletions
diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/CallbackHandlerTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/CallbackHandlerTest.java
index c14d06f..5055bfe 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/CallbackHandlerTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/CallbackHandlerTest.java
@@ -94,7 +94,6 @@ public class CallbackHandlerTest extends AndroidTestCase {
public void testSignalCallback_setMobileDataIndicators() {
IconState status = new IconState(true, 0, "");
IconState qs = new IconState(true, 1, "");
- int dark = 2;
boolean in = true;
boolean out = true;
String typeDescription = "Test 1";
@@ -103,13 +102,12 @@ public class CallbackHandlerTest extends AndroidTestCase {
int qsType = R.drawable.ic_qs_signal_1x;
boolean wide = true;
int subId = 5;
- mHandler.setMobileDataIndicators(status, qs, dark, type, qsType, in, out, typeDescription,
+ mHandler.setMobileDataIndicators(status, qs, type, qsType, in, out, typeDescription,
description, wide, subId);
waitForCallbacks();
ArgumentCaptor<IconState> statusArg = ArgumentCaptor.forClass(IconState.class);
ArgumentCaptor<IconState> qsArg = ArgumentCaptor.forClass(IconState.class);
- ArgumentCaptor<Integer> darkStrengthArg = ArgumentCaptor.forClass(Integer.class);
ArgumentCaptor<Integer> typeIconArg = ArgumentCaptor.forClass(Integer.class);
ArgumentCaptor<Integer> qsTypeIconArg = ArgumentCaptor.forClass(Integer.class);
ArgumentCaptor<Boolean> inArg = ArgumentCaptor.forClass(Boolean.class);
@@ -118,13 +116,12 @@ public class CallbackHandlerTest extends AndroidTestCase {
ArgumentCaptor<String> descArg = ArgumentCaptor.forClass(String.class);
ArgumentCaptor<Boolean> wideArg = ArgumentCaptor.forClass(Boolean.class);
ArgumentCaptor<Integer> subIdArg = ArgumentCaptor.forClass(Integer.class);
- Mockito.verify(mSignalCallback).setMobileDataIndicators(statusArg.capture(), qsArg.capture(),
- darkStrengthArg.capture(), typeIconArg.capture(), qsTypeIconArg.capture(),
- inArg.capture(), outArg.capture(), typeContentArg.capture(), descArg.capture(),
- wideArg.capture(), subIdArg.capture());
+ Mockito.verify(mSignalCallback).setMobileDataIndicators(statusArg.capture(),
+ qsArg.capture(), typeIconArg.capture(), qsTypeIconArg.capture(), inArg.capture(),
+ outArg.capture(), typeContentArg.capture(), descArg.capture(), wideArg.capture(),
+ subIdArg.capture());
assertEquals(status, statusArg.getValue());
assertEquals(qs, qsArg.getValue());
- assertEquals(dark, (int) darkStrengthArg.getValue());
assertEquals(type, (int) typeIconArg.getValue());
assertEquals(qsType, (int) qsTypeIconArg.getValue());
assertEquals(in, (boolean) inArg.getValue());
diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerBaseTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerBaseTest.java
index 2d6bb68..441bb16 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerBaseTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerBaseTest.java
@@ -258,7 +258,6 @@ public class NetworkControllerBaseTest extends SysuiTestCase {
ArgumentCaptor.forClass(IconState.class).capture(),
iconArg.capture(),
ArgumentCaptor.forClass(Integer.class).capture(),
- ArgumentCaptor.forClass(Integer.class).capture(),
typeIconArg.capture(), dataInArg.capture(), dataOutArg.capture(),
ArgumentCaptor.forClass(String.class).capture(),
ArgumentCaptor.forClass(String.class).capture(),
@@ -275,20 +274,14 @@ public class NetworkControllerBaseTest extends SysuiTestCase {
}
protected void verifyLastMobileDataIndicators(boolean visible, int icon, int typeIcon) {
- verifyLastMobileDataIndicators(visible, icon, icon, typeIcon);
- }
-
- protected void verifyLastMobileDataIndicators(boolean visible, int strengthIcon,
- int darkStrengthIcon, int typeIcon) {
ArgumentCaptor<IconState> iconArg = ArgumentCaptor.forClass(IconState.class);
- ArgumentCaptor<Integer> darkStrengthIconArg = ArgumentCaptor.forClass(Integer.class);
ArgumentCaptor<Integer> typeIconArg = ArgumentCaptor.forClass(Integer.class);
// TODO: Verify all fields.
Mockito.verify(mCallbackHandler, Mockito.atLeastOnce()).setMobileDataIndicators(
iconArg.capture(),
ArgumentCaptor.forClass(IconState.class).capture(),
- darkStrengthIconArg.capture(), typeIconArg.capture(),
+ typeIconArg.capture(),
ArgumentCaptor.forClass(Integer.class).capture(),
ArgumentCaptor.forClass(Boolean.class).capture(),
ArgumentCaptor.forClass(Boolean.class).capture(),
@@ -298,9 +291,6 @@ public class NetworkControllerBaseTest extends SysuiTestCase {
ArgumentCaptor.forClass(Integer.class).capture());
IconState iconState = iconArg.getValue();
- assertEquals("Signal strength icon in status bar", strengthIcon, iconState.icon);
- assertEquals("Signal strength icon (dark mode) in status bar", darkStrengthIcon,
- (int) darkStrengthIconArg.getValue());
assertEquals("Data icon in status bar", typeIcon, (int) typeIconArg.getValue());
assertEquals("Visibility in status bar", visible, iconState.visible);
}
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 874fdf9..dd6f272 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
@@ -438,7 +438,6 @@ public class NetworkControllerSignalTest extends NetworkControllerBaseTest {
// Out of service and carrier network change is true, show special indicator
verifyLastMobileDataIndicators(true /* visible */,
TelephonyIcons.TELEPHONY_CARRIER_NETWORK_CHANGE[0][0] /* strengthIcon */,
- TelephonyIcons.TELEPHONY_CARRIER_NETWORK_CHANGE_DARK[0][0] /* darkStrengthIcon */,
0 /* typeIcon */);
// Revert back