title: How to shim HttpWebRequest
body: <p>I have a problem trying to shim HttpWebRequest. 
  If you just add a fakes assembly of the System assembly it doesn't work instantly.
  However if you change the fakes file and add the specific namespace it works.</p>
  
  <pre><code>&lt;Fakes xmlns="http://schemas.microsoft.com/fakes/2011/"&gt;
    &lt;Assembly Name="System" Version="4.0.0.0"/&gt;
    &lt;ShimGeneration&gt;
      &lt;Clear/&gt;
      &lt;Add FullName="System.Net.WebRequest!"/&gt;
      &lt;Add FullName="System.Net.HttpWebRequest!"/&gt;
      &lt;Add FullName="System.Net.HttpWebResponse!"/&gt;
    &lt;/ShimGeneration&gt;
  &lt;/Fakes&gt;
  </code></pre>
  
  <p>The problem is that this only works locally. The Automated build on the Team Foundation Server throws an error when trying to resolve ShimHttpWebRequest. It looks like the automated build ignores the fakes file, because when i build it manually with VS on the build server, it works.</p>