< Summary

Information
Class: Elsa.Extensions.ApplicationProviderExtensions
Assembly: Elsa.Identity
File(s): /home/runner/work/elsa-core/elsa-core/src/modules/Elsa.Identity/Extensions/ApplicationProviderExtensions.cs
Line coverage
0%
Covered lines: 0
Uncovered lines: 6
Coverable lines: 6
Total lines: 29
Line coverage: 0%
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
FindByClientIdAsync()100%210%

File(s)

/home/runner/work/elsa-core/elsa-core/src/modules/Elsa.Identity/Extensions/ApplicationProviderExtensions.cs

#LineLine coverage
 1using Elsa.Identity.Contracts;
 2using Elsa.Identity.Entities;
 3using Elsa.Identity.Models;
 4
 5// ReSharper disable once CheckNamespace
 6namespace Elsa.Extensions;
 7
 8/// <summary>
 9/// Provides extensions for <see cref="IApplicationProvider"/>.
 10/// </summary>
 11public static class ApplicationProviderExtensions
 12{
 13    /// <summary>
 14    /// Finds the application with the specified client ID.
 15    /// </summary>
 16    /// <param name="applicationProvider">The user provider.</param>
 17    /// <param name="clientId">The client ID to search by.</param>
 18    /// <param name="cancellationToken">The cancellation token.</param>
 19    /// <returns>The application with the specified client ID.</returns>
 20    public static async Task<Application?> FindByClientIdAsync(this IApplicationProvider applicationProvider, string cli
 21    {
 022        var filter = new ApplicationFilter
 023        {
 024            ClientId = clientId
 025        };
 26
 027        return await applicationProvider.FindAsync(filter, cancellationToken);
 028    }
 29}

Methods/Properties

FindByClientIdAsync()