Refactor code structure and optimize performance across multiple modules
This commit is contained in:
@@ -17,7 +17,8 @@ public sealed class RequestDispatcherTests
|
||||
PropertyNameCaseInsensitive = true
|
||||
};
|
||||
|
||||
[Fact]
|
||||
[Trait("Category", TestCategories.Unit)]
|
||||
[Fact]
|
||||
public async Task DispatchAsync_WhenEndpointNotFound_Returns404()
|
||||
{
|
||||
var registry = new EndpointRegistry();
|
||||
@@ -44,7 +45,8 @@ public sealed class RequestDispatcherTests
|
||||
Encoding.UTF8.GetString(response.Payload.Span).Should().Be("Not Found");
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[Trait("Category", TestCategories.Unit)]
|
||||
[Fact]
|
||||
public async Task DispatchAsync_WhenBodyEmpty_BindsFromPathAndQueryParameters()
|
||||
{
|
||||
var registry = new EndpointRegistry();
|
||||
@@ -86,7 +88,8 @@ public sealed class RequestDispatcherTests
|
||||
dto.Filter.Should().Be("active");
|
||||
}
|
||||
|
||||
[Fact]
|
||||
[Trait("Category", TestCategories.Unit)]
|
||||
[Fact]
|
||||
public async Task DispatchAsync_WhenBodyPresent_PathAndQueryOverrideJsonProperties()
|
||||
{
|
||||
var registry = new EndpointRegistry();
|
||||
@@ -103,6 +106,7 @@ public sealed class RequestDispatcherTests
|
||||
services.AddTransient<GetItemHandler>();
|
||||
using var provider = services.BuildServiceProvider();
|
||||
|
||||
using StellaOps.TestKit;
|
||||
var dispatcher = new RequestDispatcher(
|
||||
registry,
|
||||
provider,
|
||||
|
||||
Reference in New Issue
Block a user