Loading packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerBaseTest.java +16 −9 Original line number Diff line number Diff line Loading @@ -37,6 +37,9 @@ import com.android.systemui.statusbar.policy.NetworkControllerImpl.SubscriptionD import com.android.systemui.SysuiTestCase; import org.junit.After; import org.junit.Before; import org.junit.Rule; import org.junit.rules.TestWatcher; import org.junit.runner.Description; import org.mockito.ArgumentCaptor; import org.mockito.Mockito; Loading Loading @@ -76,6 +79,19 @@ public class NetworkControllerBaseTest extends SysuiTestCase { private NetworkCapabilities mNetCapabilities; @Rule public TestWatcher failWatcher = new TestWatcher() { @Override protected void failed(Throwable e, Description description) { // Print out mNetworkController state if the test fails. StringWriter sw = new StringWriter(); PrintWriter pw = new PrintWriter(sw); mNetworkController.dump(null, pw, null); pw.flush(); Log.d(TAG, sw.toString()); } }; @Before public void setUp() throws Exception { mMockWm = mock(WifiManager.class); Loading Loading @@ -147,15 +163,6 @@ public class NetworkControllerBaseTest extends SysuiTestCase { } @After public void tearDown() throws Exception { StringWriter sw = new StringWriter(); PrintWriter pw = new PrintWriter(sw); mNetworkController.dump(null, pw, null); pw.flush(); Log.d(TAG, sw.toString()); } // 2 Bars 3G GSM. public void setupDefaultSignal() { setIsGsm(true); Loading Loading
packages/SystemUI/tests/src/com/android/systemui/statusbar/policy/NetworkControllerBaseTest.java +16 −9 Original line number Diff line number Diff line Loading @@ -37,6 +37,9 @@ import com.android.systemui.statusbar.policy.NetworkControllerImpl.SubscriptionD import com.android.systemui.SysuiTestCase; import org.junit.After; import org.junit.Before; import org.junit.Rule; import org.junit.rules.TestWatcher; import org.junit.runner.Description; import org.mockito.ArgumentCaptor; import org.mockito.Mockito; Loading Loading @@ -76,6 +79,19 @@ public class NetworkControllerBaseTest extends SysuiTestCase { private NetworkCapabilities mNetCapabilities; @Rule public TestWatcher failWatcher = new TestWatcher() { @Override protected void failed(Throwable e, Description description) { // Print out mNetworkController state if the test fails. StringWriter sw = new StringWriter(); PrintWriter pw = new PrintWriter(sw); mNetworkController.dump(null, pw, null); pw.flush(); Log.d(TAG, sw.toString()); } }; @Before public void setUp() throws Exception { mMockWm = mock(WifiManager.class); Loading Loading @@ -147,15 +163,6 @@ public class NetworkControllerBaseTest extends SysuiTestCase { } @After public void tearDown() throws Exception { StringWriter sw = new StringWriter(); PrintWriter pw = new PrintWriter(sw); mNetworkController.dump(null, pw, null); pw.flush(); Log.d(TAG, sw.toString()); } // 2 Bars 3G GSM. public void setupDefaultSignal() { setIsGsm(true); Loading