< Summary - Heimdall API

Information
Class: ArturRios.Heimdall.Command.Input.ConfirmTwoFactorAuthCommand
Assembly: ArturRios.Heimdall.Command
File(s): /home/runner/work/heimdall-api/heimdall-api/src/Application/ArturRios.Heimdall.Command/Input/ConfirmTwoFactorAuthCommand.cs
Line coverage
100%
Covered lines: 4
Uncovered lines: 0
Coverable lines: 4
Total lines: 28
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage
100%
Covered methods: 4
Fully covered methods: 4
Total methods: 4
Method coverage: 100%
Full method coverage: 100%

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
get_AppCode()100%11100%
get_EmailCode()100%11100%
get_ActingPersonId()100%11100%
get_ActingRole()100%11100%

File(s)

/home/runner/work/heimdall-api/heimdall-api/src/Application/ArturRios.Heimdall.Command/Input/ConfirmTwoFactorAuthCommand.cs

#LineLine coverage
 1using System.Text.Json.Serialization;
 2using ArturRios.Heimdall.Shared.Security;
 3using ArturRios.Mediator.Command;
 4
 5namespace ArturRios.Heimdall.Command.Input;
 6
 7/// <summary>
 8///     Intent to confirm the caller's pending two-factor authentication setup (UC-37, FR-2F-04),
 9///     proving control of every method selected in UC-36. <see cref="ActingPersonId" />/
 10///     <see cref="ActingRole" /> are set by the controller from the authenticated caller and are
 11///     never bound from the body — like <see cref="EnableTwoFactorAuthCommand" />, a caller can only
 12///     ever confirm their own configuration. They are <c>[JsonIgnore]</c>, so they are not
 13///     deserialized from the body and do not appear in the request schema.
 14/// </summary>
 15public class ConfirmTwoFactorAuthCommand : BaseCommand, IActorScoped
 16{
 17    /// <summary>The 6-digit authenticator-app code, required only when the App method is enabled.</summary>
 14718    public string? AppCode { get; set; }
 19
 20    /// <summary>The 6-digit email code, required only when the Email method is enabled.</summary>
 14121    public string? EmailCode { get; set; }
 22
 23    [JsonIgnore]
 11024    public Guid ActingPersonId { get; set; }
 25
 26    [JsonIgnore]
 5527    public int ActingRole { get; set; }
 28}