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

Side by Side Diff: ios/chrome/test/testing_application_context.mm

Issue 1956173002: Revert of network_time_tracker: add temporary time protocol. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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
« no previous file with comments | « ios/chrome/test/DEPS ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "ios/chrome/test/testing_application_context.h" 5 #include "ios/chrome/test/testing_application_context.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/memory/ptr_util.h" 8 #include "base/memory/ptr_util.h"
9 #include "base/time/default_clock.h" 9 #include "base/time/default_clock.h"
10 #include "base/time/default_tick_clock.h" 10 #include "base/time/default_tick_clock.h"
11 #include "components/network_time/network_time_tracker.h" 11 #include "components/network_time/network_time_tracker.h"
12 #include "ios/public/provider/chrome/browser/chrome_browser_provider.h" 12 #include "ios/public/provider/chrome/browser/chrome_browser_provider.h"
13 #include "net/url_request/url_request_context_getter.h"
14 13
15 TestingApplicationContext::TestingApplicationContext() 14 TestingApplicationContext::TestingApplicationContext()
16 : application_locale_("en"), 15 : application_locale_("en"),
17 local_state_(nullptr), 16 local_state_(nullptr),
18 chrome_browser_state_manager_(nullptr), 17 chrome_browser_state_manager_(nullptr),
19 was_last_shutdown_clean_(false) { 18 was_last_shutdown_clean_(false) {
20 DCHECK(!GetApplicationContext()); 19 DCHECK(!GetApplicationContext());
21 SetApplicationContext(this); 20 SetApplicationContext(this);
22 } 21 }
23 22
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 return nullptr; 120 return nullptr;
122 } 121 }
123 122
124 network_time::NetworkTimeTracker* 123 network_time::NetworkTimeTracker*
125 TestingApplicationContext::GetNetworkTimeTracker() { 124 TestingApplicationContext::GetNetworkTimeTracker() {
126 DCHECK(thread_checker_.CalledOnValidThread()); 125 DCHECK(thread_checker_.CalledOnValidThread());
127 if (!network_time_tracker_) { 126 if (!network_time_tracker_) {
128 DCHECK(local_state_); 127 DCHECK(local_state_);
129 network_time_tracker_.reset(new network_time::NetworkTimeTracker( 128 network_time_tracker_.reset(new network_time::NetworkTimeTracker(
130 base::WrapUnique(new base::DefaultClock), 129 base::WrapUnique(new base::DefaultClock),
131 base::WrapUnique(new base::DefaultTickClock), local_state_, 130 base::WrapUnique(new base::DefaultTickClock), local_state_));
132 GetSystemURLRequestContext()));
133 } 131 }
134 return network_time_tracker_.get(); 132 return network_time_tracker_.get();
135 } 133 }
136 134
137 IOSChromeIOThread* TestingApplicationContext::GetIOSChromeIOThread() { 135 IOSChromeIOThread* TestingApplicationContext::GetIOSChromeIOThread() {
138 DCHECK(thread_checker_.CalledOnValidThread()); 136 DCHECK(thread_checker_.CalledOnValidThread());
139 return nullptr; 137 return nullptr;
140 } 138 }
141 139
142 gcm::GCMDriver* TestingApplicationContext::GetGCMDriver() { 140 gcm::GCMDriver* TestingApplicationContext::GetGCMDriver() {
(...skipping 10 matching lines...) Expand all
153 component_updater::ComponentUpdateService* 151 component_updater::ComponentUpdateService*
154 TestingApplicationContext::GetComponentUpdateService() { 152 TestingApplicationContext::GetComponentUpdateService() {
155 DCHECK(thread_checker_.CalledOnValidThread()); 153 DCHECK(thread_checker_.CalledOnValidThread());
156 return nullptr; 154 return nullptr;
157 } 155 }
158 156
159 CRLSetFetcher* TestingApplicationContext::GetCRLSetFetcher() { 157 CRLSetFetcher* TestingApplicationContext::GetCRLSetFetcher() {
160 DCHECK(thread_checker_.CalledOnValidThread()); 158 DCHECK(thread_checker_.CalledOnValidThread());
161 return nullptr; 159 return nullptr;
162 } 160 }
OLDNEW
« no previous file with comments | « ios/chrome/test/DEPS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698