Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(135)

Side by Side Diff: chrome/browser/ui/sync/one_click_signin_sync_starter_unittest.cc

Issue 1408003010: [sync] Componentize switches used by ProfileSyncService (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@more_pss_chrome_deps
Patch Set: Rebase Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/sync/one_click_signin_sync_starter.h" 5 #include "chrome/browser/ui/sync/one_click_signin_sync_starter.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
11 #include "chrome/browser/signin/account_tracker_service_factory.h" 11 #include "chrome/browser/signin/account_tracker_service_factory.h"
12 #include "chrome/browser/signin/chrome_signin_client_factory.h" 12 #include "chrome/browser/signin/chrome_signin_client_factory.h"
13 #include "chrome/browser/signin/gaia_cookie_manager_service_factory.h" 13 #include "chrome/browser/signin/gaia_cookie_manager_service_factory.h"
14 #include "chrome/browser/signin/profile_oauth2_token_service_factory.h" 14 #include "chrome/browser/signin/profile_oauth2_token_service_factory.h"
15 #include "chrome/browser/signin/signin_manager_factory.h" 15 #include "chrome/browser/signin/signin_manager_factory.h"
16 #include "chrome/common/chrome_switches.h" 16 #include "chrome/common/chrome_switches.h"
17 #include "chrome/test/base/chrome_render_view_host_test_harness.h" 17 #include "chrome/test/base/chrome_render_view_host_test_harness.h"
18 #include "chrome/test/base/testing_profile.h" 18 #include "chrome/test/base/testing_profile.h"
19 #include "components/browser_sync/common/browser_sync_switches.h"
19 #include "components/signin/core/browser/account_tracker_service.h" 20 #include "components/signin/core/browser/account_tracker_service.h"
20 #include "components/signin/core/browser/fake_signin_manager.h" 21 #include "components/signin/core/browser/fake_signin_manager.h"
21 #include "content/public/browser/navigation_entry.h" 22 #include "content/public/browser/navigation_entry.h"
22 #include "content/public/browser/web_contents.h" 23 #include "content/public/browser/web_contents.h"
23 #include "content/public/test/test_browser_thread_bundle.h" 24 #include "content/public/test/test_browser_thread_bundle.h"
24 #include "testing/gtest/include/gtest/gtest.h" 25 #include "testing/gtest/include/gtest/gtest.h"
25 26
26 namespace { 27 namespace {
27 28
28 const char* kTestingGaiaId = "gaia_id"; 29 const char* kTestingGaiaId = "gaia_id";
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 138
138 const GURL kTestURL = GURL("http://www.example.com"); 139 const GURL kTestURL = GURL("http://www.example.com");
139 CreateSyncStarter(base::Bind(&OneClickSigninSyncStarterTest::Callback, 140 CreateSyncStarter(base::Bind(&OneClickSigninSyncStarterTest::Callback,
140 base::Unretained(this)), 141 base::Unretained(this)),
141 kTestURL); 142 kTestURL);
142 sync_starter_->AccountAddedToCookie( 143 sync_starter_->AccountAddedToCookie(
143 GoogleServiceAuthError(GoogleServiceAuthError::NONE)); 144 GoogleServiceAuthError(GoogleServiceAuthError::NONE));
144 EXPECT_EQ(1, succeeded_count_); 145 EXPECT_EQ(1, succeeded_count_);
145 EXPECT_EQ(kTestURL, controller.GetPendingEntry()->GetURL()); 146 EXPECT_EQ(kTestURL, controller.GetPendingEntry()->GetURL());
146 } 147 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698