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

Information
Class: Microsoft.Extensions.DependencyInjection.DbSeederSqlServerRegistration
Assembly: ZhEaIsNsAaBn.DbSeeder.SqlServer
File(s): /home/runner/work/ZhEaIsNsAaBn.Libraries.V1/ZhEaIsNsAaBn.Libraries.V1/src/DataBasePackages/ZhEaIsNsAaBn.DbSeeder.SqlServer/DbSeederSqlServerRegistration.cs
Line coverage
100%
Covered lines: 2
Uncovered lines: 0
Coverable lines: 2
Total lines: 29
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
UseSqlServer(...)100%11100%

File(s)

/home/runner/work/ZhEaIsNsAaBn.Libraries.V1/ZhEaIsNsAaBn.Libraries.V1/src/DataBasePackages/ZhEaIsNsAaBn.DbSeeder.SqlServer/DbSeederSqlServerRegistration.cs

#LineLine coverage
 1#region Usings
 2using ZhEaIsNsAaBn.DbSeeder.Registrations;
 3using ZhEaIsNsAaBn.DbSeeder.SqlServer;
 4#endregion
 5
 6// ReSharper disable once CheckNamespace
 7namespace Microsoft.Extensions.DependencyInjection;
 8
 9/// <summary>Seeder-builder entry point of the SQL Server seed provider.</summary>
 10public static class DbSeederSqlServerRegistration
 11{
 12    /// <summary>
 13    /// Uses SQL Server for the seed migrations of this context: <c>sp_getapplock</c>, bulk copy + <c>UPDATE</c> / <c>IN
 14    /// (no <c>MERGE</c>), explicit identity values kept, set-based deletes, foreign-key blockers from the database. Onl
 15    /// The context must use <c>UseSqlServer( … )</c>.
 16    /// </summary>
 17    /// <typeparam name="TDbContext">The context type.</typeparam>
 18    /// <param name="builder">The seeder builder.</param>
 19    /// <returns>The same builder.</returns>
 20    /// <exception cref="ArgumentNullException"><paramref name="builder"/> is <see langword="null"/>.</exception>
 21    /// <example><code>services.AddDbSeeder&lt;AppDbContext&gt;().FromAssembly( assembly ).UseSqlServer().Build();</code
 22    public static IDbSeederBuilder<TDbContext> UseSqlServer< TDbContext >( this IDbSeederBuilder<TDbContext> builder )
 23        where TDbContext : DbContext
 24    {
 53025        ArgumentNullException.ThrowIfNull( builder );
 26
 53027        return builder.UseProvider( _ => SqlServerSeedDatabaseProvider.Instance );
 28    }
 29}