| OLD | NEW |
| 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 206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 217 | 217 |
| 218 // Triggers a sync error on the server. | 218 // Triggers a sync error on the server. |
| 219 // error: The error the server is expected to return. | 219 // error: The error the server is expected to return. |
| 220 // frequency: Frequency with which the error is returned. | 220 // frequency: Frequency with which the error is returned. |
| 221 void TriggerSyncError(const syncer::SyncProtocolError& error, | 221 void TriggerSyncError(const syncer::SyncProtocolError& error, |
| 222 SyncErrorFrequency frequency); | 222 SyncErrorFrequency frequency); |
| 223 | 223 |
| 224 // Triggers the creation the Synced Bookmarks folder on the server. | 224 // Triggers the creation the Synced Bookmarks folder on the server. |
| 225 void TriggerCreateSyncedBookmarks(); | 225 void TriggerCreateSyncedBookmarks(); |
| 226 | 226 |
| 227 // Returns the number of default items that every client syncs. | |
| 228 int NumberOfDefaultSyncItems() const; | |
| 229 | |
| 230 protected: | 227 protected: |
| 231 // Add custom switches needed for running the test. | 228 // Add custom switches needed for running the test. |
| 232 virtual void AddTestSwitches(CommandLine* cl); | 229 virtual void AddTestSwitches(CommandLine* cl); |
| 233 | 230 |
| 234 // Append the command line switches to enable experimental types that aren't | 231 // Append the command line switches to enable experimental types that aren't |
| 235 // on by default yet. | 232 // on by default yet. |
| 236 virtual void AddOptionalTypesToCommandLine(CommandLine* cl); | 233 virtual void AddOptionalTypesToCommandLine(CommandLine* cl); |
| 237 | 234 |
| 238 // InProcessBrowserTest override. Destroys all the sync clients and sync | 235 // InProcessBrowserTest override. Destroys all the sync clients and sync |
| 239 // profiles created by a test. | 236 // profiles created by a test. |
| (...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 380 | 377 |
| 381 // Used to start and stop the local test server. | 378 // Used to start and stop the local test server. |
| 382 base::ProcessHandle test_server_handle_; | 379 base::ProcessHandle test_server_handle_; |
| 383 | 380 |
| 384 // Fake URLFetcher factory used to mock out GAIA signin. | 381 // Fake URLFetcher factory used to mock out GAIA signin. |
| 385 scoped_ptr<net::FakeURLFetcherFactory> fake_factory_; | 382 scoped_ptr<net::FakeURLFetcherFactory> fake_factory_; |
| 386 | 383 |
| 387 // The URLFetcherImplFactory instance used to instantiate |fake_factory_|. | 384 // The URLFetcherImplFactory instance used to instantiate |fake_factory_|. |
| 388 scoped_ptr<net::URLFetcherImplFactory> factory_; | 385 scoped_ptr<net::URLFetcherImplFactory> factory_; |
| 389 | 386 |
| 390 // Number of default entries (as determined by the existing entries at setup | |
| 391 // time on client 0). | |
| 392 size_t number_of_default_sync_items_; | |
| 393 | |
| 394 DISALLOW_COPY_AND_ASSIGN(SyncTest); | 387 DISALLOW_COPY_AND_ASSIGN(SyncTest); |
| 395 }; | 388 }; |
| 396 | 389 |
| 397 #endif // CHROME_BROWSER_SYNC_TEST_INTEGRATION_SYNC_TEST_H_ | 390 #endif // CHROME_BROWSER_SYNC_TEST_INTEGRATION_SYNC_TEST_H_ |
| OLD | NEW |