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

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

Issue 11759019: Update other unittests to use newly added TestingBrowserProcess::GetGlobal(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: simpler codez Created 7 years, 11 months 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/utf_string_conversions.h" 6 #include "base/utf_string_conversions.h"
7 #include "chrome/browser/content_settings/cookie_settings.h" 7 #include "chrome/browser/content_settings/cookie_settings.h"
8 #include "chrome/browser/prefs/pref_service.h" 8 #include "chrome/browser/prefs/pref_service.h"
9 #include "chrome/browser/prefs/scoped_user_pref_update.h" 9 #include "chrome/browser/prefs/scoped_user_pref_update.h"
10 #include "chrome/browser/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after
283 private: 283 private:
284 content::TestBrowserThread db_thread_; 284 content::TestBrowserThread db_thread_;
285 content::TestBrowserThread fub_thread_; 285 content::TestBrowserThread fub_thread_;
286 content::TestBrowserThread io_thread_; 286 content::TestBrowserThread io_thread_;
287 287
288 DISALLOW_COPY_AND_ASSIGN(OneClickSigninHelperIOTest); 288 DISALLOW_COPY_AND_ASSIGN(OneClickSigninHelperIOTest);
289 }; 289 };
290 290
291 OneClickSigninHelperIOTest::OneClickSigninHelperIOTest() 291 OneClickSigninHelperIOTest::OneClickSigninHelperIOTest()
292 : testing_profile_manager_( 292 : testing_profile_manager_(
293 static_cast<TestingBrowserProcess*>(g_browser_process)), 293 TestingBrowserProcess::GetGlobal()),
294 valid_gaia_url_("https://accounts.google.com/"), 294 valid_gaia_url_("https://accounts.google.com/"),
295 db_thread_(content::BrowserThread::DB, &message_loop_), 295 db_thread_(content::BrowserThread::DB, &message_loop_),
296 fub_thread_(content::BrowserThread::FILE_USER_BLOCKING, &message_loop_), 296 fub_thread_(content::BrowserThread::FILE_USER_BLOCKING, &message_loop_),
297 io_thread_(content::BrowserThread::IO, &message_loop_) { 297 io_thread_(content::BrowserThread::IO, &message_loop_) {
298 } 298 }
299 299
300 OneClickSigninHelperIOTest::~OneClickSigninHelperIOTest() { 300 OneClickSigninHelperIOTest::~OneClickSigninHelperIOTest() {
301 } 301 }
302 302
303 void OneClickSigninHelperIOTest::SetUp() { 303 void OneClickSigninHelperIOTest::SetUp() {
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
664 valid_gaia_url_, "", &request_, io_data.get())); 664 valid_gaia_url_, "", &request_, io_data.get()));
665 } 665 }
666 666
667 TEST_F(OneClickSigninHelperIOTest, CanOfferOnIOThreadNoSigninCookies) { 667 TEST_F(OneClickSigninHelperIOTest, CanOfferOnIOThreadNoSigninCookies) {
668 AllowSigninCookies(false); 668 AllowSigninCookies(false);
669 scoped_ptr<TestProfileIOData> io_data(CreateTestProfileIOData(false)); 669 scoped_ptr<TestProfileIOData> io_data(CreateTestProfileIOData(false));
670 EXPECT_EQ(OneClickSigninHelper::DONT_OFFER, 670 EXPECT_EQ(OneClickSigninHelper::DONT_OFFER,
671 OneClickSigninHelper::CanOfferOnIOThreadImpl( 671 OneClickSigninHelper::CanOfferOnIOThreadImpl(
672 valid_gaia_url_, "", &request_, io_data.get())); 672 valid_gaia_url_, "", &request_, io_data.get()));
673 } 673 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/cocoa_profile_test.mm ('k') | chrome/browser/ui/tab_contents/tab_contents_iterator_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698