title: Is it possible to mock a system service in Android
body: <p>all. I'm new to use Mockito:)</p>
  
  <pre><code>Context mockContext = mock(Context.class);
  TelephonyManager mockTelephonyManager = mock(TelephonyManager.class);
  when(mockTelephonyManager.getNetworkCountryIso()).thenReturn("CN");
  
  when(mockContext.getSystemService(Context.TELEPHONY_SERVICE)).thenReturn(mockTelephonyManager);
  </code></pre>
  
  <p>the above won't work when espresso test trying to use the telephony, it still return the system network country ISO. any thoughts? thanks!</p>