Searched refs:networkInfo (Results 1 – 5 of 5) sorted by relevance
18 NetworkInfo networkInfo = Robolectric.newInstanceOf(NetworkInfo.class); in getDetailedState_shouldReturnTheAssignedState() local19 shadowOf(networkInfo).setDetailedState(NetworkInfo.DetailedState.SCANNING); in getDetailedState_shouldReturnTheAssignedState()20 assertThat(networkInfo.getDetailedState(), equalTo(NetworkInfo.DetailedState.SCANNING)); in getDetailedState_shouldReturnTheAssignedState()
48 … NetworkInfo networkInfo = ShadowNetworkInfo.newInstance(NetworkInfo.DetailedState.CONNECTING); in getNetworkInfoShouldReturnAssignedValue() local49 shadowConnectivityManager.setNetworkInfo(ConnectivityManager.TYPE_WIFI, networkInfo); in getNetworkInfoShouldReturnAssignedValue()51 assertThat(actual, sameInstance(networkInfo)); in getNetworkInfoShouldReturnAssignedValue()
55 NetworkInfo networkInfo = connectivityManager.getActiveNetworkInfo(); in isConnected() local56 return networkInfo != null && networkInfo.isConnected(); in isConnected()
34 NetworkInfo networkInfo = Robolectric.newInstanceOf(NetworkInfo.class); in newInstance() local35 final ShadowNetworkInfo info = shadowOf(networkInfo); in newInstance()41 return networkInfo; in newInstance()
48 public void setNetworkInfo(int networkType, NetworkInfo networkInfo) { in setNetworkInfo() argument49 networkTypeToNetworkInfo.put(networkType, networkInfo); in setNetworkInfo()