Loading src/java/com/android/internal/telephony/dataconnection/DataConnection.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -816,7 +816,7 @@ public class DataConnection extends StateMachine { * * * This gets set once per connection setup and is based on conditions at that time. * This gets set once per connection setup and is based on conditions at that time. * We could theoretically have dynamic capabilities but now is not a good time to * We could theoretically have dynamic capabilities but now is not a good time to * experiement with that. * experiment with that. * * * This flag overrides the APN-based restriction capability, restricting the network * This flag overrides the APN-based restriction capability, restricting the network * based on both having a NetworkRequest with restricted AND needing a restricted * based on both having a NetworkRequest with restricted AND needing a restricted Loading src/java/com/android/internal/telephony/dataconnection/DcTracker.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -1556,7 +1556,7 @@ public class DcTracker extends Handler { boolean isEmergencyApn = apnContext.getApnType().equals(PhoneConstants.APN_TYPE_EMERGENCY); boolean isEmergencyApn = apnContext.getApnType().equals(PhoneConstants.APN_TYPE_EMERGENCY); final ServiceStateTracker sst = mPhone.getServiceStateTracker(); final ServiceStateTracker sst = mPhone.getServiceStateTracker(); // set to false if apn type is non-metered or if we have a restricted (priveleged) // set to false if apn type is non-metered or if we have a restricted (privileged) // request for the network. // request for the network. // TODO - may want restricted requests to only apply to carrier-limited data access // TODO - may want restricted requests to only apply to carrier-limited data access // rather than applying to user limited as well. // rather than applying to user limited as well. Loading tests/telephonytests/src/com/android/internal/telephony/dataconnection/DcTrackerTest.java +5 −4 Original line number Original line Diff line number Diff line Loading @@ -28,7 +28,6 @@ import static org.mockito.Matchers.anyInt; import static org.mockito.Matchers.anyLong; import static org.mockito.Matchers.anyLong; import static org.mockito.Matchers.anyString; import static org.mockito.Matchers.anyString; import static org.mockito.Matchers.eq; import static org.mockito.Matchers.eq; import static org.mockito.Matchers.nullable; import static org.mockito.Mockito.doAnswer; import static org.mockito.Mockito.doAnswer; import static org.mockito.Mockito.doReturn; import static org.mockito.Mockito.doReturn; import static org.mockito.Mockito.never; import static org.mockito.Mockito.never; Loading Loading @@ -705,9 +704,6 @@ public class DcTrackerTest extends TelephonyTest { mDct.setDataEnabled(true); mDct.setDataEnabled(true); waitForMs(200); waitForMs(200); verify(mSimulatedCommandsVerifier, times(1)).setInitialAttachApn(any(DataProfile.class), eq(true), nullable(Message.class)); ArgumentCaptor<DataProfile> dpCaptor = ArgumentCaptor.forClass(DataProfile.class); ArgumentCaptor<DataProfile> dpCaptor = ArgumentCaptor.forClass(DataProfile.class); verify(mSimulatedCommandsVerifier, times(1)).setupDataCall( verify(mSimulatedCommandsVerifier, times(1)).setupDataCall( eq(ServiceState.RIL_RADIO_TECHNOLOGY_UMTS), dpCaptor.capture(), eq(ServiceState.RIL_RADIO_TECHNOLOGY_UMTS), dpCaptor.capture(), Loading @@ -717,6 +713,11 @@ public class DcTrackerTest extends TelephonyTest { assertEquals(DctConstants.State.CONNECTED, mDct.getOverallState()); assertEquals(DctConstants.State.CONNECTED, mDct.getOverallState()); assertEquals(DctConstants.State.IDLE, mDct.getState(PhoneConstants.APN_TYPE_DEFAULT)); assertEquals(DctConstants.State.IDLE, mDct.getState(PhoneConstants.APN_TYPE_DEFAULT)); assertEquals(DctConstants.State.CONNECTED, mDct.getState(PhoneConstants.APN_TYPE_IMS)); assertEquals(DctConstants.State.CONNECTED, mDct.getState(PhoneConstants.APN_TYPE_IMS)); // reset roaming settings / data enabled settings at end of this test mDct.setDataOnRoamingEnabled(roamingEnabled); mDct.setDataEnabled(dataEnabled); waitForMs(200); } } // Test the default data switch scenario. // Test the default data switch scenario. Loading Loading
src/java/com/android/internal/telephony/dataconnection/DataConnection.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -816,7 +816,7 @@ public class DataConnection extends StateMachine { * * * This gets set once per connection setup and is based on conditions at that time. * This gets set once per connection setup and is based on conditions at that time. * We could theoretically have dynamic capabilities but now is not a good time to * We could theoretically have dynamic capabilities but now is not a good time to * experiement with that. * experiment with that. * * * This flag overrides the APN-based restriction capability, restricting the network * This flag overrides the APN-based restriction capability, restricting the network * based on both having a NetworkRequest with restricted AND needing a restricted * based on both having a NetworkRequest with restricted AND needing a restricted Loading
src/java/com/android/internal/telephony/dataconnection/DcTracker.java +1 −1 Original line number Original line Diff line number Diff line Loading @@ -1556,7 +1556,7 @@ public class DcTracker extends Handler { boolean isEmergencyApn = apnContext.getApnType().equals(PhoneConstants.APN_TYPE_EMERGENCY); boolean isEmergencyApn = apnContext.getApnType().equals(PhoneConstants.APN_TYPE_EMERGENCY); final ServiceStateTracker sst = mPhone.getServiceStateTracker(); final ServiceStateTracker sst = mPhone.getServiceStateTracker(); // set to false if apn type is non-metered or if we have a restricted (priveleged) // set to false if apn type is non-metered or if we have a restricted (privileged) // request for the network. // request for the network. // TODO - may want restricted requests to only apply to carrier-limited data access // TODO - may want restricted requests to only apply to carrier-limited data access // rather than applying to user limited as well. // rather than applying to user limited as well. Loading
tests/telephonytests/src/com/android/internal/telephony/dataconnection/DcTrackerTest.java +5 −4 Original line number Original line Diff line number Diff line Loading @@ -28,7 +28,6 @@ import static org.mockito.Matchers.anyInt; import static org.mockito.Matchers.anyLong; import static org.mockito.Matchers.anyLong; import static org.mockito.Matchers.anyString; import static org.mockito.Matchers.anyString; import static org.mockito.Matchers.eq; import static org.mockito.Matchers.eq; import static org.mockito.Matchers.nullable; import static org.mockito.Mockito.doAnswer; import static org.mockito.Mockito.doAnswer; import static org.mockito.Mockito.doReturn; import static org.mockito.Mockito.doReturn; import static org.mockito.Mockito.never; import static org.mockito.Mockito.never; Loading Loading @@ -705,9 +704,6 @@ public class DcTrackerTest extends TelephonyTest { mDct.setDataEnabled(true); mDct.setDataEnabled(true); waitForMs(200); waitForMs(200); verify(mSimulatedCommandsVerifier, times(1)).setInitialAttachApn(any(DataProfile.class), eq(true), nullable(Message.class)); ArgumentCaptor<DataProfile> dpCaptor = ArgumentCaptor.forClass(DataProfile.class); ArgumentCaptor<DataProfile> dpCaptor = ArgumentCaptor.forClass(DataProfile.class); verify(mSimulatedCommandsVerifier, times(1)).setupDataCall( verify(mSimulatedCommandsVerifier, times(1)).setupDataCall( eq(ServiceState.RIL_RADIO_TECHNOLOGY_UMTS), dpCaptor.capture(), eq(ServiceState.RIL_RADIO_TECHNOLOGY_UMTS), dpCaptor.capture(), Loading @@ -717,6 +713,11 @@ public class DcTrackerTest extends TelephonyTest { assertEquals(DctConstants.State.CONNECTED, mDct.getOverallState()); assertEquals(DctConstants.State.CONNECTED, mDct.getOverallState()); assertEquals(DctConstants.State.IDLE, mDct.getState(PhoneConstants.APN_TYPE_DEFAULT)); assertEquals(DctConstants.State.IDLE, mDct.getState(PhoneConstants.APN_TYPE_DEFAULT)); assertEquals(DctConstants.State.CONNECTED, mDct.getState(PhoneConstants.APN_TYPE_IMS)); assertEquals(DctConstants.State.CONNECTED, mDct.getState(PhoneConstants.APN_TYPE_IMS)); // reset roaming settings / data enabled settings at end of this test mDct.setDataOnRoamingEnabled(roamingEnabled); mDct.setDataEnabled(dataEnabled); waitForMs(200); } } // Test the default data switch scenario. // Test the default data switch scenario. Loading