title: How can I test android application for network errors?
body: <p>I have content management application that uses TCP/IP to fetch data. I would like to test this application for several network problems like packet loss and connection lost.</p>
  
  <p>Is there some easy way to emulate network problems to test Android application?</p>
  
  <p>In DDMS there is some connection and latency setting for device, hovewer it looks like this is not working. I can set <em>denied</em> or <em>unregistered</em> but fetching from server is untouched. I'm using Windows for development.</p>
  
  <hr>
  
  <p>I have tried so far:</p>
  
  <p>F8 - 3G icon disappears, however I'm still able to download data.</p>
  
  <p>DDMS, Change of Telephony status - 3G icon disappears, however I'm still able to download data.</p>
  
  <p>Settings, Mobile networks, Data enabled false - 3G icon disappears, however I'm still able to download </p>
  
  <p>Airplane mode - 3G icon disappears, however I'm still able to download</p>
  
  <p>Dev tools - Wifi toggle - I'm getting errors:</p>
  
  <pre><code>09-27 16:43:31.353: ERROR/Connectivity(518): EVENT_TOGGLE_WIFI
  09-27 16:43:31.363: ERROR/WifiService(62): Failed to load Wi-Fi driver.
  </code></pre>