< Summary

Information
Class: Elsa.Expressions.Liquid.Providers.LiquidExpressionDescriptorProvider
Assembly: Elsa.Expressions.Liquid
File(s): /home/runner/work/elsa-core/elsa-core/src/modules/Elsa.Expressions.Liquid/Providers/LiquidExpressionSyntaxProvider.cs
Line coverage
100%
Covered lines: 8
Uncovered lines: 0
Coverable lines: 8
Total lines: 30
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
GetDescriptors()100%11100%

File(s)

/home/runner/work/elsa-core/elsa-core/src/modules/Elsa.Expressions.Liquid/Providers/LiquidExpressionSyntaxProvider.cs

#LineLine coverage
 1using Elsa.Expressions.Contracts;
 2using Elsa.Expressions.Models;
 3using Elsa.Extensions;
 4using Elsa.Expressions.Liquid.Expressions;
 5using Microsoft.Extensions.DependencyInjection;
 6
 7namespace Elsa.Expressions.Liquid.Providers;
 8
 9/// <summary>
 10/// Provides Liquid expression descriptors.
 11/// </summary>
 12public class LiquidExpressionDescriptorProvider : IExpressionDescriptorProvider
 13{
 14    /// <summary>
 15    /// Gets the name of the expression type.
 16    /// </summary>
 17    public const string TypeName = "Liquid";
 18
 19    /// <inheritdoc />
 20    public IEnumerable<ExpressionDescriptor> GetDescriptors()
 21    {
 122        yield return new()
 123        {
 124            Type = TypeName,
 125            DisplayName = "Liquid",
 126            Properties = new { MonacoLanguage = "liquid" }.ToDictionary(),
 127            HandlerFactory = ActivatorUtilities.GetServiceOrCreateInstance<LiquidExpressionHandler>
 128        };
 129    }
 30}

Methods/Properties

GetDescriptors()