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

Side by Side Diff: chrome/test/base/testing_profile.cc

Issue 18112018: Cleanup the UseSharedProxies preference. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased. Created 7 years, 5 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
« no previous file with comments | « chrome/common/pref_names.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "chrome/test/base/testing_profile.h" 5 #include "chrome/test/base/testing_profile.h"
6 6
7 #include "build/build_config.h" 7 #include "build/build_config.h"
8 8
9 #include "base/base_paths.h" 9 #include "base/base_paths.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 711 matching lines...) Expand 10 before | Expand all | Expand 10 after
722 base::FilePath TestingProfile::last_selected_directory() { 722 base::FilePath TestingProfile::last_selected_directory() {
723 return last_selected_directory_; 723 return last_selected_directory_;
724 } 724 }
725 725
726 void TestingProfile::set_last_selected_directory(const base::FilePath& path) { 726 void TestingProfile::set_last_selected_directory(const base::FilePath& path) {
727 last_selected_directory_ = path; 727 last_selected_directory_ = path;
728 } 728 }
729 729
730 PrefProxyConfigTracker* TestingProfile::GetProxyConfigTracker() { 730 PrefProxyConfigTracker* TestingProfile::GetProxyConfigTracker() {
731 if (!pref_proxy_config_tracker_.get()) { 731 if (!pref_proxy_config_tracker_.get()) {
732 // TestingProfile is used in unit tests, where local state is not available.
732 pref_proxy_config_tracker_.reset( 733 pref_proxy_config_tracker_.reset(
733 ProxyServiceFactory::CreatePrefProxyConfigTracker(GetPrefs())); 734 ProxyServiceFactory::CreatePrefProxyConfigTrackerOfProfile(GetPrefs(),
735 NULL));
734 } 736 }
735 return pref_proxy_config_tracker_.get(); 737 return pref_proxy_config_tracker_.get();
736 } 738 }
737 739
738 void TestingProfile::BlockUntilHistoryProcessesPendingRequests() { 740 void TestingProfile::BlockUntilHistoryProcessesPendingRequests() {
739 HistoryService* history_service = 741 HistoryService* history_service =
740 HistoryServiceFactory::GetForProfile(this, Profile::EXPLICIT_ACCESS); 742 HistoryServiceFactory::GetForProfile(this, Profile::EXPLICIT_ACCESS);
741 DCHECK(history_service); 743 DCHECK(history_service);
742 DCHECK(base::MessageLoop::current()); 744 DCHECK(base::MessageLoop::current());
743 745
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
809 811
810 scoped_ptr<TestingProfile> TestingProfile::Builder::Build() { 812 scoped_ptr<TestingProfile> TestingProfile::Builder::Build() {
811 DCHECK(!build_called_); 813 DCHECK(!build_called_);
812 build_called_ = true; 814 build_called_ = true;
813 return scoped_ptr<TestingProfile>(new TestingProfile( 815 return scoped_ptr<TestingProfile>(new TestingProfile(
814 path_, 816 path_,
815 delegate_, 817 delegate_,
816 extension_policy_, 818 extension_policy_,
817 pref_service_.Pass())); 819 pref_service_.Pass()));
818 } 820 }
OLDNEW
« no previous file with comments | « chrome/common/pref_names.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698