I am writing a Downloader (for fun with TDD), in that i have a method, whose responsibility is to connect to the file.

```
class FileConnectorHttp : IFileConnector
{
public void ConnectToFile()
{
  //creating a concrete web request here.
  HttpWebRequest webRequest = (HttpWebRequest)WebRequest.Create(UriForTheFileToConnect);

  //sending HEAD request.
  webRequest.Method = "HEAD";

  //other logic for connection will go here.
  try
  {
    HttpWebResponse response = webRequest.GetResponse() as HttpWebResponse;

  }
  catch (ProtocolViolationException e)
  {
    throw;
  }
  catch (InvalidOperationException e)
  {

    throw;
  }

}
}

```

I wrote a test for testing the scenario of connection timeout.

```
[Test]
public void ConnectToSourceFile_ValidUri_Connection_TimeOut_Throws_WebException()
{
  Uri uriForTheFileToDownload = new Uri("https://suppose/this/is/valid/url.txt");

  FileConnectorHttp fileConnectorOverHttp = new FileConnectorHttp(uriForTheFileToDownload);

  Assert.Throws(Is.TypeOf<WebException>(),

    () => fileConnectorOverHttp.ConnectToFile());

}

```

So to get this exception should i turn off my Wifi connection? What should be the meaningful way to test for this kind of exception?