< Summary

Information
Class: NexusLabs.Needlr.AgentFramework.Evaluation.QualityGateFailedException
Assembly: NexusLabs.Needlr.AgentFramework.Evaluation
File(s): /home/runner/work/needlr/needlr/src/NexusLabs.Needlr.AgentFramework.Evaluation/QualityGateFailedException.cs
Line coverage
100%
Covered lines: 5
Uncovered lines: 0
Coverable lines: 5
Total lines: 22
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
get_Violations()100%11100%
.ctor(...)100%11100%

File(s)

/home/runner/work/needlr/needlr/src/NexusLabs.Needlr.AgentFramework.Evaluation/QualityGateFailedException.cs

#LineLine coverage
 1namespace NexusLabs.Needlr.AgentFramework.Evaluation;
 2
 3/// <summary>
 4/// Thrown by <see cref="EvaluationQualityGate.Assert"/> when one or more
 5/// evaluation metrics violate their configured thresholds.
 6/// </summary>
 7public sealed class QualityGateFailedException : Exception
 8{
 9    /// <summary>Gets the individual threshold violations that triggered the failure.</summary>
 810    public IReadOnlyList<string> Violations { get; }
 11
 12    /// <summary>
 13    /// Creates a new exception from the list of threshold violations.
 14    /// </summary>
 15    /// <param name="violations">One or more violation descriptions.</param>
 16    public QualityGateFailedException(IReadOnlyList<string> violations)
 517        : base($"Quality gate failed with {violations.Count} violation(s):\n" +
 1318               string.Join("\n", violations.Select(v => $"  • {v}")))
 19    {
 520        Violations = violations;
 521    }
 22}