< Summary

Information
Class: Elsa.Api.Client.Shared.Models.PropertyBag
Assembly: Elsa.Api.Client
File(s): /home/runner/work/elsa-core/elsa-core/src/clients/Elsa.Api.Client/Shared/Models/PropertyBag.cs
Line coverage
0%
Covered lines: 0
Uncovered lines: 6
Coverable lines: 6
Total lines: 22
Line coverage: 0%
Branch coverage
0%
Covered branches: 0
Total branches: 2
Branch coverage: 0%
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
.ctor()100%210%
.ctor(...)0%620%

File(s)

/home/runner/work/elsa-core/elsa-core/src/clients/Elsa.Api.Client/Shared/Models/PropertyBag.cs

#LineLine coverage
 1using System.Text.Json.Serialization;
 2
 3namespace Elsa.Api.Client.Shared.Models;
 4
 5/// <summary>
 6/// A dictionary of values that is skipped by polymorphic serialization.
 7/// </summary>
 8public class PropertyBag : Dictionary<string, object>
 9{
 10    /// <inheritdoc />
 11    [JsonConstructor]
 012    public PropertyBag() : base(StringComparer.OrdinalIgnoreCase)
 13    {
 014    }
 15
 16    /// <inheritdoc />
 017    public PropertyBag(IDictionary<string, object> dictionary) : this()
 18    {
 019        foreach (var kvp in dictionary)
 020            Add(kvp.Key, kvp.Value);
 021    }
 22}