< Summary

Information
Class: NexusLabs.Needlr.Carter.CarterWebApplicationPlugin
Assembly: NexusLabs.Needlr.Carter
File(s): /home/runner/work/needlr/needlr/src/NexusLabs.Needlr.Carter/CarterWebApplicationPlugin.cs
Line coverage
100%
Covered lines: 5
Uncovered lines: 0
Coverable lines: 5
Total lines: 24
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
Configure(...)100%11100%

File(s)

/home/runner/work/needlr/needlr/src/NexusLabs.Needlr.Carter/CarterWebApplicationPlugin.cs

#LineLine coverage
 1using Carter;
 2
 3using Microsoft.Extensions.Logging;
 4
 5using NexusLabs.Needlr.AspNet;
 6
 7namespace NexusLabs.Needlr.Carter;
 8
 9/// <summary>
 10/// Plugin that configures Carter middleware on the web application.
 11/// Maps Carter routes after the application has been built.
 12/// </summary>
 13public sealed class CarterWebApplicationPlugin : IWebApplicationPlugin
 14{
 15    /// <inheritdoc />
 16    public void Configure(WebApplicationPluginOptions options)
 17    {
 518        ArgumentNullException.ThrowIfNull(options);
 19
 420        options.WebApplication.Logger.LogInformation("Configuring Carter middleware...");
 421        options.WebApplication.MapCarter();
 422        options.WebApplication.Logger.LogInformation("Carter middleware configured successfully.");
 423    }
 24}