public static RequestBuilder WithIdentity(this RequestBuilder requestBuilder, IEnumerable <Claim> claims)
        {
            requestBuilder.AddHeader(
                Constants.AuthenticationHeaderName,
                $"{TestServerAuthenticationDefaults.AuthenticationScheme} {DefautClaimsEncoder.Encode(claims)}");

            return(requestBuilder);
        }
        public static HttpClient WithDefaultIdentity(this HttpClient httpClient, IEnumerable <Claim> claims)
        {
            httpClient.DefaultRequestHeaders.Authorization =
                new AuthenticationHeaderValue(
                    TestServerAuthenticationDefaults.AuthenticationScheme,
                    DefautClaimsEncoder.Encode(claims));

            return(httpClient);
        }