mirror of
https://github.com/wiremock/WireMock.Net.git
synced 2026-03-26 11:01:03 +01:00
Add WebProxySettings (use when proxying requests) (#370)
* webproxy part 1 * fixed * Push to MyGet * WebProxy standalone * -n true * nuget --- "-n true" * AllowAutoRedirect * .
This commit is contained in:
@@ -105,6 +105,24 @@ namespace WireMock.Net.ConsoleApplication
|
||||
.WithProxy(new ProxyAndRecordSettings { Url = "http://postman-echo.com/get" })
|
||||
);
|
||||
|
||||
server
|
||||
.Given(Request.Create()
|
||||
.UsingGet()
|
||||
.WithHeader("postmanecho", "get2")
|
||||
)
|
||||
.RespondWith(Response.Create()
|
||||
.WithProxy(new ProxyAndRecordSettings
|
||||
{
|
||||
Url = "http://postman-echo.com/get",
|
||||
WebProxySettings = new WebProxySettings
|
||||
{
|
||||
Address = "http://company",
|
||||
UserName = "test",
|
||||
Password = "pwd"
|
||||
}
|
||||
})
|
||||
);
|
||||
|
||||
server
|
||||
.Given(Request.Create()
|
||||
.UsingGet()
|
||||
|
||||
Reference in New Issue
Block a user