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

Side by Side Diff: chrome/browser/sync/test/integration/sync_test.h

Issue 308963006: Convert Sync BirthdayErrorTest to use FakeServer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 6 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
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 #ifndef CHROME_BROWSER_SYNC_TEST_INTEGRATION_SYNC_TEST_H_ 5 #ifndef CHROME_BROWSER_SYNC_TEST_INTEGRATION_SYNC_TEST_H_
6 #define CHROME_BROWSER_SYNC_TEST_INTEGRATION_SYNC_TEST_H_ 6 #define CHROME_BROWSER_SYNC_TEST_INTEGRATION_SYNC_TEST_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 void TriggerNotification(syncer::ModelTypeSet changed_types); 227 void TriggerNotification(syncer::ModelTypeSet changed_types);
228 228
229 // Returns true if the server being used supports injecting errors. 229 // Returns true if the server being used supports injecting errors.
230 bool ServerSupportsErrorTriggering() const; 230 bool ServerSupportsErrorTriggering() const;
231 231
232 // Triggers a migration for one or more datatypes, and waits 232 // Triggers a migration for one or more datatypes, and waits
233 // for the server to complete it. This operation is available 233 // for the server to complete it. This operation is available
234 // only if ServerSupportsErrorTriggering() returned true. 234 // only if ServerSupportsErrorTriggering() returned true.
235 void TriggerMigrationDoneError(syncer::ModelTypeSet model_types); 235 void TriggerMigrationDoneError(syncer::ModelTypeSet model_types);
236 236
237 // Triggers the server to set its birthday to a random value thereby
238 // the server would return a birthday error on next sync.
239 void TriggerBirthdayError();
240
241 // Triggers a transient error on the server. Note the server will stay in 237 // Triggers a transient error on the server. Note the server will stay in
242 // this state until shut down. 238 // this state until shut down.
243 void TriggerTransientError(); 239 void TriggerTransientError();
244 240
245 // Sets / unsets an auth error on the server. Can be used to simulate the case 241 // Sets / unsets an auth error on the server. Can be used to simulate the case
246 // when the user's gaia password is changed at another location, or their 242 // when the user's gaia password is changed at another location, or their
247 // OAuth2 tokens have expired. The server will stay in this state until 243 // OAuth2 tokens have expired. The server will stay in this state until
248 // this method is called with a different value. 244 // this method is called with a different value.
249 void TriggerAuthState(PythonServerAuthState auth_state); 245 void TriggerAuthState(PythonServerAuthState auth_state);
250 246
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
432 // Fake URLFetcher factory used to mock out GAIA signin. 428 // Fake URLFetcher factory used to mock out GAIA signin.
433 scoped_ptr<net::FakeURLFetcherFactory> fake_factory_; 429 scoped_ptr<net::FakeURLFetcherFactory> fake_factory_;
434 430
435 // The URLFetcherImplFactory instance used to instantiate |fake_factory_|. 431 // The URLFetcherImplFactory instance used to instantiate |fake_factory_|.
436 scoped_ptr<net::URLFetcherImplFactory> factory_; 432 scoped_ptr<net::URLFetcherImplFactory> factory_;
437 433
438 DISALLOW_COPY_AND_ASSIGN(SyncTest); 434 DISALLOW_COPY_AND_ASSIGN(SyncTest);
439 }; 435 };
440 436
441 #endif // CHROME_BROWSER_SYNC_TEST_INTEGRATION_SYNC_TEST_H_ 437 #endif // CHROME_BROWSER_SYNC_TEST_INTEGRATION_SYNC_TEST_H_
OLDNEW
« no previous file with comments | « chrome/browser/sync/test/integration/sync_errors_test.cc ('k') | chrome/browser/sync/test/integration/sync_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698