#include "content/browser/webid/federated_provider_fetcher.h"
#include "base/test/bind.h"
#include "base/test/scoped_feature_list.h"
#include "content/browser/webid/test/mock_idp_network_request_manager.h"
#include "content/test/test_render_frame_host.h"
#include "content/test/test_web_contents.h"
#include "net/http/http_status_code.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "url/gurl.h"
#include "url/origin.h"
FetchStatus;
ParseStatus;
_;
StrictMock;
WithArg;
namespace content {
class FederatedProviderFetcherTest : public RenderViewHostImplTestHarness { … };
TEST_F(FederatedProviderFetcherTest, FailedToFetchWellKnown) { … }
TEST_F(FederatedProviderFetcherTest, FailedToFetchWellKnownButNoEnforcement) { … }
TEST_F(FederatedProviderFetcherTest, FailedToFetchConfig) { … }
TEST_F(FederatedProviderFetcherTest, SucceedsToFetchConfigButInvalidResponse) { … }
TEST_F(FederatedProviderFetcherTest, SuccessfullAndValidResponse) { … }
TEST_F(FederatedProviderFetcherTest,
TooManyProvidersInWellKnownLeadsToErrorWellKnownTooBig) { … }
TEST_F(FederatedProviderFetcherTest,
ProvidersUrlsIgnoredWhenAuthZIsEnabledAndAccountEndpointsMatch) { … }
TEST_F(FederatedProviderFetcherTest, ValidFetchResult) { … }
TEST_F(FederatedProviderFetcherTest, InvalidMissingAcccountsEndpoint) { … }
TEST_F(FederatedProviderFetcherTest, InvalidCrossOriginAcccountsEndpoint) { … }
TEST_F(FederatedProviderFetcherTest, InvalidMissingTokenEndpoint) { … }
TEST_F(FederatedProviderFetcherTest, InvalidCrossOriginTokenEndpoint) { … }
TEST_F(FederatedProviderFetcherTest, InvalidCrossOriginSigninUrl) { … }
TEST_F(FederatedProviderFetcherTest, InvalidConfigUrlNotInProviders) { … }
TEST_F(FederatedProviderFetcherTest, InvalidConfigUrlNotInWellKnown) { … }
TEST_F(FederatedProviderFetcherTest, InvalidWellKnownTooManyProviders) { … }
TEST_F(FederatedProviderFetcherTest, SkippingTheChecksWithTheWellKnownFlag) { … }
TEST_F(FederatedProviderFetcherTest, InvalidWellKnownWithoutSignInUrl) { … }
TEST_F(FederatedProviderFetcherTest, InvalidWellKnownWithoutAccountsEndpoint) { … }
TEST_F(FederatedProviderFetcherTest,
ValidWellKnownWithMatchingAccountsAndSignInUrl) { … }
TEST_F(FederatedProviderFetcherTest,
FailResultEvenIfConfigUrlMatchesWhenAccountsEndpointIsAvailable) { … }
TEST_F(FederatedProviderFetcherTest, InvalidEmptyConfig) { … }
TEST_F(FederatedProviderFetcherTest, InvalidNetworkError) { … }
}