mirror of
https://github.com/wiremock/WireMock.Net.git
synced 2026-03-25 19:02:24 +01:00
Rewrite some unit-integration-tests to unit-tests (#206)
This commit is contained in:
@@ -19,7 +19,7 @@ namespace WireMock.Net.Tests
|
||||
server.SetBasicAuthentication("x", "y");
|
||||
|
||||
// Assert
|
||||
var options = server.GetPrivateFieldValue<WireMockMiddlewareOptions>("_options");
|
||||
var options = server.GetPrivateFieldValue<IWireMockMiddlewareOptions>("_options");
|
||||
Check.That(options.AuthorizationMatcher.Name).IsEqualTo("RegexMatcher");
|
||||
Check.That(options.AuthorizationMatcher.MatchBehaviour).IsEqualTo(MatchBehaviour.AcceptOnMatch);
|
||||
Check.That(options.AuthorizationMatcher.GetPatterns()).ContainsExactly("^(?i)BASIC eDp5$");
|
||||
@@ -36,7 +36,7 @@ namespace WireMock.Net.Tests
|
||||
server.RemoveBasicAuthentication();
|
||||
|
||||
// Assert
|
||||
var options = server.GetPrivateFieldValue<WireMockMiddlewareOptions>("_options");
|
||||
var options = server.GetPrivateFieldValue<IWireMockMiddlewareOptions>("_options");
|
||||
Check.That(options.AuthorizationMatcher).IsNull();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user