public async Task DeleteClientSecretAsync()
        {
            using (var context = new AdminDbContext(_dbContextOptions, _storeOptions, _operationalStore))
            {
                IClientRepository clientRepository = new ClientRepository(context);

                //Generate random new client without id
                var client = ClientMock.GenerateRandomClient(0);

                //Add new client
                await clientRepository.AddClientAsync(client);

                //Get new client
                var clientEntity = await clientRepository.GetClientAsync(client.Id);

                //Assert new client
                clientEntity.Should().BeEquivalentTo(client, options => options.Excluding(o => o.Id));

                //Generate random new Client Secret
                var clientSecret = ClientMock.GenerateRandomClientSecret(0);

                //Add new client secret
                await clientRepository.AddClientSecretAsync(clientEntity.Id, clientSecret);

                //Get new client secret
                var newSecret = await context.ClientSecrets.Where(x => x.Id == clientSecret.Id).SingleOrDefaultAsync();

                //Asert
                newSecret.Should().BeEquivalentTo(clientSecret,
                                                  options => options.Excluding(o => o.Id).Excluding(x => x.Client));

                //Try delete it
                await clientRepository.DeleteClientSecretAsync(newSecret);

                //Get new client secret
                var deletedSecret =
                    await context.ClientSecrets.Where(x => x.Id == clientSecret.Id).SingleOrDefaultAsync();

                //Assert
                deletedSecret.Should().BeNull();
            }
        }
        public void CanMapClientSecretToModel()
        {
            var clientSecret = ClientMock.GenerateRandomClientSecret(0);

            var clientSecretsDto = clientSecret.ToModel();

            //Assert
            clientSecretsDto.Should().NotBeNull();

            clientSecret.Should().BeEquivalentTo(clientSecretsDto, options =>
                                                 options.Excluding(o => o.ClientSecretId)
                                                 .Excluding(o => o.ClientSecrets)
                                                 .Excluding(o => o.ClientName)
                                                 .Excluding(o => o.PageSize)
                                                 .Excluding(o => o.TotalCount)
                                                 .Excluding(o => o.HashType)
                                                 .Excluding(o => o.HashTypes)
                                                 .Excluding(o => o.HashTypeEnum)
                                                 .Excluding(o => o.TypeList)
                                                 .Excluding(o => o.ClientId));
        }