Exemplo n.º 1
0
        public void Can_build_logout_url()
        {
            var authenticationApiClient = new AuthenticationApiClient(new Uri(GetVariable("AUTH0_AUTHENTICATION_API_URL")));

            var logoutUrl = authenticationApiClient.BuildLogoutUrl()
                .Build();

            logoutUrl.Should()
                .Be(
                    @"https://auth0-dotnet-integration-tests.auth0.com/logout");
        }
Exemplo n.º 2
0
        public void Can_build_logout_url()
        {
            var authenticationApiClient = new AuthenticationApiClient(new Uri(GetVariable("AUTH0_AUTHENTICATION_API_URL")));

            var logoutUrl = authenticationApiClient.BuildLogoutUrl()
                            .Build();

            logoutUrl.Should()
            .Be(
                @"https://auth0-dotnet-integration-tests.auth0.com/logout");
        }
Exemplo n.º 3
0
        public void Can_build_logout_url_with_return_url()
        {
            var authenticationApiClient = new AuthenticationApiClient(new Uri(GetVariable("AUTH0_AUTHENTICATION_API_URL")));

            var logoutUrl = authenticationApiClient.BuildLogoutUrl()
                .WithReturnUrl("http://www.jerriepelser.com/test")
                .Build();

            logoutUrl.Should()
                .Be(
                    @"https://auth0-dotnet-integration-tests.auth0.com/logout?returnTo=http:%2F%2Fwww.jerriepelser.com%2Ftest");
        }
Exemplo n.º 4
0
        public void Can_build_logout_url_with_return_url_as_uri()
        {
            var authenticationApiClient = new AuthenticationApiClient(GetVariable("AUTH0_AUTHENTICATION_API_URL"));

            var logoutUrl = authenticationApiClient.BuildLogoutUrl()
                            .WithReturnUrl(new Uri("http://www.jerriepelser.com/test"))
                            .Build();

            logoutUrl.Should()
            .Be(
                @"https://auth0-dotnet-integration-tests.auth0.com/v2/logout?returnTo=http%3A%2F%2Fwww.jerriepelser.com%2Ftest");
        }
Exemplo n.º 5
0
        public void Can_build_logout_url_with_federated()
        {
            var authenticationApiClient = new AuthenticationApiClient(GetVariable("AUTH0_AUTHENTICATION_API_URL"));

            var logoutUrl = authenticationApiClient.BuildLogoutUrl()
                            .Federated()
                            .WithReturnUrl(new Uri("http://www.jerriepelser.com/test"))
                            .Build();

            logoutUrl.Should()
            .Be(
                @"https://dx-sdks-testing.us.auth0.com/v2/logout?federated&returnTo=http%3A%2F%2Fwww.jerriepelser.com%2Ftest");
        }
Exemplo n.º 6
0
        public void Can_build_logout_url()
        {
            var authenticationApiClient = new AuthenticationApiClient(GetVariable("AUTH0_AUTHENTICATION_API_URL"));

            var logoutUrl = authenticationApiClient.BuildLogoutUrl()
                            .Federated()
                            .WithClientId("rLNKKMORlaDzrMTqGtSL9ZSXiBBksCQW")
                            .WithReturnUrl("https://myapp/logged_out")
                            .Build();

            logoutUrl.Should()
            .Be(
                @"https://auth0-dotnet-integration-tests.auth0.com/v2/logout?federated&client_id=rLNKKMORlaDzrMTqGtSL9ZSXiBBksCQW&returnTo=https%3A%2F%2Fmyapp%2Flogged_out");
        }