< Summary

Information
Class: Elsa.Persistence.EFCore.Modules.Labels.LabelsElsaDbContext
Assembly: Elsa.Persistence.EFCore
File(s): /home/runner/work/elsa-core/elsa-core/src/modules/Elsa.Persistence.EFCore/Modules/Labels/DbContext.cs
Line coverage
100%
Covered lines: 9
Uncovered lines: 0
Coverable lines: 9
Total lines: 24
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%
get_Labels()100%11100%
get_WorkflowDefinitionLabels()100%11100%
OnModelCreating(...)100%11100%

File(s)

/home/runner/work/elsa-core/elsa-core/src/modules/Elsa.Persistence.EFCore/Modules/Labels/DbContext.cs

#LineLine coverage
 1using Elsa.Labels.Entities;
 2using Microsoft.EntityFrameworkCore;
 3
 4namespace Elsa.Persistence.EFCore.Modules.Labels;
 5
 6public class LabelsElsaDbContext : ElsaDbContextBase
 7{
 1358    public LabelsElsaDbContext(DbContextOptions<LabelsElsaDbContext> options, IServiceProvider serviceProvider) : base(o
 9    {
 13510    }
 11
 14212    public DbSet<Label> Labels { get; set; } = null!;
 13513    public DbSet<WorkflowDefinitionLabel> WorkflowDefinitionLabels { get; set; } = null!;
 14
 15    /// <inheritdoc />
 16    protected override void OnModelCreating(ModelBuilder modelBuilder)
 17    {
 218        base.OnModelCreating(modelBuilder);
 19
 220        var config = new Configurations();
 221        modelBuilder.ApplyConfiguration<Label>(config);
 222        modelBuilder.ApplyConfiguration<WorkflowDefinitionLabel>(config);
 223    }
 24}