justeat/JustFakeIt — pull request #3 by davidwhitney (2014-11-02 16:42:52+00:00)
Title: Re-worked request interception to configure itself as the default system proxy

When the server starts, the system proxy registers itself, and unmodified calls to any Url can be hooked and intercepted.
Currently only tested against the existing WebRequest test cases - need to verify against other libraries. Anything that respects the system proxy configuration should work unfettered. Original "direct" use-case still works correctly.

Apologies for the horrible line endings conversion in the FakeServerScenarios - file had inconsistent endings.

Breaking changes: FakeServer is now configured with just a port, as it hosts on 127.0.0.1 instead of a hostname.
New Features:

[Fact]
public void FakeServer_RequestingAUriThatHasNotBeenModified_ResponseMatchesExpectation()
{
using (var fakeServer = new FakeServer(12354))
{
fakeServer.Expect.Get("/123").Returns("Some String Data");
fakeServer.Start();

var result = new WebClient().DownloadString(new Uri("http://www.bing.com/123"));

result.Should().Be("Some String Data");
}
}

Works.