< Summary

Information
Class: Elsa.Workflows.Services.WorkflowLoggerStateGenerator
Assembly: Elsa.Workflows.Core
File(s): /home/runner/work/elsa-core/elsa-core/src/modules/Elsa.Workflows.Core/Services/WorkflowLoggerStateGenerator.cs
Line coverage
100%
Covered lines: 4
Uncovered lines: 0
Coverable lines: 4
Total lines: 20
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
GenerateLoggerState(...)100%11100%

File(s)

/home/runner/work/elsa-core/elsa-core/src/modules/Elsa.Workflows.Core/Services/WorkflowLoggerStateGenerator.cs

#LineLine coverage
 1namespace Elsa.Workflows.Services;
 2
 3/// <summary>
 4/// Generates logger state for the specified <see cref="WorkflowExecutionContext"/>.
 5/// </summary>
 6public class WorkflowLoggerStateGenerator : ILoggerStateGenerator<WorkflowExecutionContext>
 7{
 8    /// <summary>
 9    /// Generates logger state for the specified <see cref="WorkflowExecutionContext"/>.
 10    /// </summary>
 11    /// <param name="workflowExecutionContext">The <see cref="WorkflowExecutionContext"/> to generate logger state for.<
 12    /// <returns>A <see cref="Dictionary{String, Object}" /> containing the state related to the <see cref="WorkflowExec
 13    public Dictionary<string, object> GenerateLoggerState(WorkflowExecutionContext workflowExecutionContext)
 14    {
 43615        return new Dictionary<string, object>
 43616        {
 43617            ["WorkflowInstanceId"] = workflowExecutionContext.Id
 43618        };
 19    }
 20}