OLD | NEW |
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/browser/sync/test/integration/sync_test.h" | 5 #include "chrome/browser/sync/test/integration/sync_test.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
212 | 212 |
213 // Disable non-essential access of external network resources. | 213 // Disable non-essential access of external network resources. |
214 if (!cl->HasSwitch(switches::kDisableBackgroundNetworking)) | 214 if (!cl->HasSwitch(switches::kDisableBackgroundNetworking)) |
215 cl->AppendSwitch(switches::kDisableBackgroundNetworking); | 215 cl->AppendSwitch(switches::kDisableBackgroundNetworking); |
216 } | 216 } |
217 | 217 |
218 void SyncTest::AddOptionalTypesToCommandLine(CommandLine* cl) { | 218 void SyncTest::AddOptionalTypesToCommandLine(CommandLine* cl) { |
219 // TODO(sync): Remove this once sessions sync is enabled by default. | 219 // TODO(sync): Remove this once sessions sync is enabled by default. |
220 if (!cl->HasSwitch(switches::kEnableSyncTabs)) | 220 if (!cl->HasSwitch(switches::kEnableSyncTabs)) |
221 cl->AppendSwitch(switches::kEnableSyncTabs); | 221 cl->AppendSwitch(switches::kEnableSyncTabs); |
222 // TODO(kalman): Remove this once extension/app settings sync is enabled by | |
223 // default. | |
224 if (!cl->HasSwitch(switches::kEnableSyncExtensionSettings)) | |
225 cl->AppendSwitch(switches::kEnableSyncExtensionSettings); | |
226 } | 222 } |
227 | 223 |
228 // static | 224 // static |
229 Profile* SyncTest::MakeProfile(const FilePath::StringType name) { | 225 Profile* SyncTest::MakeProfile(const FilePath::StringType name) { |
230 FilePath path; | 226 FilePath path; |
231 PathService::Get(chrome::DIR_USER_DATA, &path); | 227 PathService::Get(chrome::DIR_USER_DATA, &path); |
232 path = path.Append(name); | 228 path = path.Append(name); |
233 | 229 |
234 if (!file_util::PathExists(path)) | 230 if (!file_util::PathExists(path)) |
235 CHECK(file_util::CreateDirectory(path)); | 231 CHECK(file_util::CreateDirectory(path)); |
(...skipping 526 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
762 | 758 |
763 void SyncTest::SetProxyConfig(net::URLRequestContextGetter* context_getter, | 759 void SyncTest::SetProxyConfig(net::URLRequestContextGetter* context_getter, |
764 const net::ProxyConfig& proxy_config) { | 760 const net::ProxyConfig& proxy_config) { |
765 base::WaitableEvent done(false, false); | 761 base::WaitableEvent done(false, false); |
766 BrowserThread::PostTask( | 762 BrowserThread::PostTask( |
767 BrowserThread::IO, FROM_HERE, | 763 BrowserThread::IO, FROM_HERE, |
768 base::Bind(&SetProxyConfigCallback, &done, | 764 base::Bind(&SetProxyConfigCallback, &done, |
769 make_scoped_refptr(context_getter), proxy_config)); | 765 make_scoped_refptr(context_getter), proxy_config)); |
770 done.Wait(); | 766 done.Wait(); |
771 } | 767 } |
OLD | NEW |