< Summary - ZhEaIsNsAaBn.Libraries coverage (affected: 23 packages)

Information
Class: ZhEaIsNsAaBn.Infrastructure.Specifications.SingleSpecification<T>
Assembly: ZhEaIsNsAaBn.Infrastructure.Specifications
File(s): /home/runner/work/ZhEaIsNsAaBn.Libraries.V1/ZhEaIsNsAaBn.Libraries.V1/src/DataBasePackages/ZhEaIsNsAaBn.Infrastructure.Specifications/Specifications/SingleSpecification.cs
Line coverage
100%
Covered lines: 4
Uncovered lines: 0
Coverable lines: 4
Total lines: 17
Line coverage: 100%
Branch coverage
50%
Covered branches: 1
Total branches: 2
Branch coverage: 50%
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
.ctor(...)50%22100%

File(s)

/home/runner/work/ZhEaIsNsAaBn.Libraries.V1/ZhEaIsNsAaBn.Libraries.V1/src/DataBasePackages/ZhEaIsNsAaBn.Infrastructure.Specifications/Specifications/SingleSpecification.cs

#LineLine coverage
 1namespace ZhEaIsNsAaBn.Infrastructure.Specifications;
 2
 3/// <summary>A single-row query, no-tracking unless the filter asks for tracking; derive and add criteria.</summary>
 4/// <typeparam name="TEntity">The entity type.</typeparam>
 5public abstract class SingleSpecification< TEntity > : BaseSpecification<TEntity>
 6    where TEntity : class
 7{
 8    /// <summary>Creates the specification.</summary>
 9    /// <param name="filter">The filter.</param>
 10    /// <exception cref="ArgumentNullException"><paramref name="filter"/> is <see langword="null"/>.</exception>
 10411    protected SingleSpecification( ISingleFilter<TEntity> filter )
 12    {
 10413        ArgumentNullException.ThrowIfNull( filter );
 14
 20815        if ( filter.AsNoTracking ) { Query.AsNoTracking(); }
 10416    }
 17}