Table of Contents

Class TestUserProfileService

Namespace
Fdyay.IdentityServer.Test
Assembly
Fdyay.IdentityServer.Core.dll

A profile service sourced from an ITestUserStore.

public sealed class TestUserProfileService : IProfileService
Inheritance
TestUserProfileService
Implements
Inherited Members

Constructors

TestUserProfileService(ITestUserStore)

Creates the profile service over the test users.

public TestUserProfileService(ITestUserStore users)

Parameters

users ITestUserStore

The test users the subject is looked up in.

Methods

GetProfileDataAsync(ProfileDataRequestContext, CancellationToken)

Adds the requested claims to IssuedClaims.

public Task GetProfileDataAsync(ProfileDataRequestContext context, CancellationToken cancellationToken = default)

Parameters

context ProfileDataRequestContext
cancellationToken CancellationToken

Returns

Task

Remarks

Adds the requested claims from the test user whose subject id is the subject's sub; none when no user matches.

Exceptions

ArgumentNullException

context is null.

IsActiveAsync(IsActiveContext, CancellationToken)

Determines whether the subject is still active and allowed to receive tokens.

public Task IsActiveAsync(IsActiveContext context, CancellationToken cancellationToken = default)

Parameters

context IsActiveContext
cancellationToken CancellationToken

Returns

Task

Remarks

Active only when a test user has the subject's sub and its IsActive is true.

Exceptions

ArgumentNullException

context is null.