Removed unwanted logging for non-matching routes
This commit is contained in:
parent
33c098355c
commit
0882a393a4
|
|
@ -110,12 +110,6 @@ namespace Microsoft.AspNet.Routing.Template
|
|||
if (values == null)
|
||||
{
|
||||
// If we got back a null value set, that means the URI did not match
|
||||
|
||||
_logger.LogVerbose(
|
||||
"Request did not match the route with name '{RouteName}' and template '{RouteTemplate}'.",
|
||||
Name,
|
||||
RouteTemplate);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -100,26 +100,6 @@ namespace Microsoft.AspNet.Routing.Template
|
|||
Assert.Equal(expected, sink.Writes[0].State?.ToString());
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public async Task RouteAsync_MatchFailOnValues_LogsCorrectValues()
|
||||
{
|
||||
// Arrange & Act
|
||||
var routeName = "Default";
|
||||
var template = "{controller}/{action}";
|
||||
var result = await SetUp(
|
||||
routeName: routeName,
|
||||
template: template,
|
||||
requestPath: "/Home/Index/Failure",
|
||||
loggerEnabled: true);
|
||||
var sink = result.Item1;
|
||||
var expected = $"Request did not match the route with name '{routeName}' and template '{template}'.";
|
||||
|
||||
// Assert
|
||||
Assert.Empty(sink.Scopes);
|
||||
Assert.Single(sink.Writes);
|
||||
Assert.Equal(expected, sink.Writes[0].State?.ToString());
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public async Task RouteAsync_MatchFailOnConstraints_LogsCorrectValues()
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue