public static async Task <HttpClient> SetDelegateSessionAndGetClient(
     AuthenticationWebApplicationFactory <Startup> factory,
     int delegateId
     )
 {
     return(await GetClient(factory).GetAsyncAndSetCookie($"/SetDelegateTestSession?delegateId={delegateId}"));
 }
        public CreateAccountShould(
            AuthenticationWebApplicationFactory <Startup> factory)
        {
            var client = factory.CreateClient(new WebApplicationFactoryClientOptions {
                AllowAutoRedirect = false
            });

            _requestHelper = new RequestHelper(client);
        }
        private static HttpClient GetClient(AuthenticationWebApplicationFactory <Startup> factory)
        {
            var client = factory.CreateClient(
                new WebApplicationFactoryClientOptions
            {
                HandleCookies     = false,
                AllowAutoRedirect = false,
            }
                );

            return(client);
        }
예제 #4
0
 public LinkLearningHubSsoTests(AuthenticationWebApplicationFactory <Startup> factory)
 {
     _factory = factory;
 }