| Index: chrome/browser/ui/webui/options/sync_setup_handler_unittest.cc
|
| diff --git a/chrome/browser/ui/webui/options/sync_setup_handler_unittest.cc b/chrome/browser/ui/webui/options/sync_setup_handler_unittest.cc
|
| index 7fcc635894a07323a8ded6d3769cc75b53bdad9e..56531c8e2feae3a384aea0d81a997555c80a0edd 100644
|
| --- a/chrome/browser/ui/webui/options/sync_setup_handler_unittest.cc
|
| +++ b/chrome/browser/ui/webui/options/sync_setup_handler_unittest.cc
|
| @@ -313,7 +313,8 @@ TEST_F(SyncSetupHandlerFirstSigninTest, DisplayBasicLogin) {
|
| // Ensure that the user is not signed in before calling |HandleStartSignin()|.
|
| SigninManager* manager = static_cast<SigninManager*>(mock_signin_);
|
| manager->SignOut(signin_metrics::SIGNOUT_TEST);
|
| - handler_->HandleStartSignin(NULL);
|
| + base::ListValue list_args;
|
| + handler_->HandleStartSignin(&list_args);
|
|
|
| // Sync setup hands off control to the gaia login tab.
|
| EXPECT_EQ(NULL,
|
| @@ -394,7 +395,7 @@ TEST_F(SyncSetupHandlerTest,
|
| EXPECT_CALL(*mock_pss_, IsBackendInitialized()).WillRepeatedly(Return(false));
|
| SetDefaultExpectationsForConfigPage();
|
|
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| // We expect a call to SyncSetupOverlay.showSyncSetupPage.
|
| EXPECT_EQ(1U, web_ui_.call_data().size());
|
| @@ -443,7 +444,7 @@ TEST_F(SyncSetupHandlerTest,
|
| .WillOnce(Return(false))
|
| .WillRepeatedly(Return(true));
|
| SetDefaultExpectationsForConfigPage();
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| // It's important to tell sync the user cancelled the setup flow before we
|
| // tell it we're through with the setup progress.
|
| @@ -465,7 +466,7 @@ TEST_F(SyncSetupHandlerTest,
|
| error_ = GoogleServiceAuthError::AuthErrorNone();
|
| EXPECT_CALL(*mock_pss_, IsBackendInitialized()).WillRepeatedly(Return(false));
|
|
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
| const content::TestWebUI::CallData& data = *web_ui_.call_data()[0];
|
| EXPECT_EQ("SyncSetupOverlay.showSyncSetupPage", data.function_name());
|
| std::string page;
|
| @@ -497,7 +498,7 @@ TEST_F(SyncSetupHandlerNonCrosTest, HandleGaiaAuthFailure) {
|
| EXPECT_CALL(*mock_pss_, HasSyncSetupCompleted())
|
| .WillRepeatedly(Return(false));
|
| // Open the web UI.
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| ASSERT_FALSE(handler_->is_configuring_sync());
|
| }
|
| @@ -508,7 +509,7 @@ TEST_F(SyncSetupHandlerNonCrosTest, UnrecoverableErrorInitializingSync) {
|
| EXPECT_CALL(*mock_pss_, HasSyncSetupCompleted())
|
| .WillRepeatedly(Return(false));
|
| // Open the web UI.
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| ASSERT_FALSE(handler_->is_configuring_sync());
|
| }
|
| @@ -518,7 +519,7 @@ TEST_F(SyncSetupHandlerNonCrosTest, GaiaErrorInitializingSync) {
|
| EXPECT_CALL(*mock_pss_, HasSyncSetupCompleted())
|
| .WillRepeatedly(Return(false));
|
| // Open the web UI.
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| ASSERT_FALSE(handler_->is_configuring_sync());
|
| }
|
| @@ -741,7 +742,7 @@ TEST_F(SyncSetupHandlerTest, ShowSyncSetup) {
|
| SetupInitializedProfileSyncService();
|
| // This should display the sync setup dialog (not login).
|
| SetDefaultExpectationsForConfigPage();
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| ExpectConfig();
|
| }
|
| @@ -776,7 +777,7 @@ TEST_F(SyncSetupHandlerTest, ShowSigninOnAuthError) {
|
|
|
| // On ChromeOS, this should display the spinner while we try to startup the
|
| // sync backend, and on desktop this displays the login dialog.
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| // Sync setup is closed when re-auth is in progress.
|
| EXPECT_EQ(NULL,
|
| @@ -795,7 +796,7 @@ TEST_F(SyncSetupHandlerTest, ShowSetupSyncEverything) {
|
| SetupInitializedProfileSyncService();
|
| SetDefaultExpectationsForConfigPage();
|
| // This should display the sync setup dialog (not login).
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| ExpectConfig();
|
| const content::TestWebUI::CallData& data = *web_ui_.call_data()[0];
|
| @@ -830,7 +831,7 @@ TEST_F(SyncSetupHandlerTest, ShowSetupManuallySyncAll) {
|
| sync_prefs.SetKeepEverythingSynced(false);
|
| SetDefaultExpectationsForConfigPage();
|
| // This should display the sync setup dialog (not login).
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| ExpectConfig();
|
| const content::TestWebUI::CallData& data = *web_ui_.call_data()[0];
|
| @@ -857,7 +858,7 @@ TEST_F(SyncSetupHandlerTest, ShowSetupSyncForAllTypesIndividually) {
|
| WillRepeatedly(Return(types));
|
|
|
| // This should display the sync setup dialog (not login).
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| ExpectConfig();
|
| // Close the config overlay.
|
| @@ -882,7 +883,7 @@ TEST_F(SyncSetupHandlerTest, ShowSetupGaiaPassphraseRequired) {
|
| SetDefaultExpectationsForConfigPage();
|
|
|
| // This should display the sync setup dialog (not login).
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| ExpectConfig();
|
| const content::TestWebUI::CallData& data = *web_ui_.call_data()[0];
|
| @@ -904,7 +905,7 @@ TEST_F(SyncSetupHandlerTest, ShowSetupCustomPassphraseRequired) {
|
| SetDefaultExpectationsForConfigPage();
|
|
|
| // This should display the sync setup dialog (not login).
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| ExpectConfig();
|
| const content::TestWebUI::CallData& data = *web_ui_.call_data()[0];
|
| @@ -926,7 +927,7 @@ TEST_F(SyncSetupHandlerTest, ShowSetupEncryptAll) {
|
| .WillRepeatedly(Return(true));
|
|
|
| // This should display the sync setup dialog (not login).
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| ExpectConfig();
|
| const content::TestWebUI::CallData& data = *web_ui_.call_data()[0];
|
| @@ -946,7 +947,7 @@ TEST_F(SyncSetupHandlerTest, ShowSetupEncryptAllDisallowed) {
|
| .WillRepeatedly(Return(false));
|
|
|
| // This should display the sync setup dialog (not login).
|
| - handler_->OpenSyncSetup(nullptr);
|
| + handler_->OpenSyncSetup(false /* creating_supervised_user */);
|
|
|
| ExpectConfig();
|
| const content::TestWebUI::CallData& data = *web_ui_.call_data()[0];
|
| @@ -977,4 +978,3 @@ TEST_F(SyncSetupHandlerTest, TurnOnEncryptAllDisallowed) {
|
| // passphrase.
|
| ExpectDone();
|
| }
|
| -
|
|
|