< Summary

Information
Class: FLP.Application.Validators.Bugs.UpdateBugValidator
Assembly: FLP.Application
File(s): /home/runner/work/FLP.AzureFunctions/FLP.AzureFunctions/FLP.Application/Validators/Bugs/UpdateBugValidator.cs
Line coverage
100%
Covered lines: 22
Uncovered lines: 0
Coverable lines: 22
Total lines: 35
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
.ctor()100%11100%

File(s)

/home/runner/work/FLP.AzureFunctions/FLP.AzureFunctions/FLP.Application/Validators/Bugs/UpdateBugValidator.cs

#LineLine coverage
 1using FLP.Application.Requests.Bugs;
 2using FluentValidation;
 3
 4namespace FLP.Application.Validators.Bugs;
 5
 6internal class UpdateBugValidator : AbstractValidator<UpdateBugRequest>
 7{
 48    public UpdateBugValidator()
 49    {
 10
 411        RuleFor(f => f.Id)
 412            .NotEmpty()
 413            .WithMessage("Id is required.")
 414            .Must(id => id != Guid.Empty)
 415            .WithMessage("Id must be a valid GUID and cannot be an empty GUID.");
 16
 417        RuleFor(f => f.Title)
 418            .MinimumLength(5)
 419            .WithMessage("Title must be at least 5 characters long.")
 420            .MaximumLength(50)
 421            .WithMessage("Title must not exceed 50 characters.")
 422            .NotEmpty()
 423            .WithMessage("Title is required.");
 24
 425        RuleFor(f => f.Description)
 426            .MinimumLength(10)
 427            .WithMessage("Description must be at least 10 characters long.")
 428            .MaximumLength(500)
 429            .WithMessage("Description must not exceed 500 characters.")
 430            .NotEmpty()
 431            .WithMessage("Description is required.");
 32
 33
 434    }
 35}

Methods/Properties

.ctor()