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

Unified Diff: chrome/browser/sync/profile_sync_test_util.h

Issue 2002012: sync: Add location info to unrecoverable error. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Add error handler back to bookmark model associator Created 10 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/sync/profile_sync_test_util.h
===================================================================
--- chrome/browser/sync/profile_sync_test_util.h (revision 48898)
+++ chrome/browser/sync/profile_sync_test_util.h (working copy)
@@ -58,16 +58,11 @@
task->Run();
}
-template <class ModelAssociatorImpl>
-class TestModelAssociator : public ModelAssociatorImpl {
+class TestModelAssociatorHelper {
public:
- explicit TestModelAssociator(
- ProfileSyncService* service,
- browser_sync::UnrecoverableErrorHandler* error_handler)
- : ModelAssociatorImpl(service, error_handler) {
- }
-
- virtual bool GetSyncIdForTaggedNode(const std::string& tag, int64* sync_id) {
+ template <class ModelAssociatorImpl>
+ bool GetSyncIdForTaggedNode(ModelAssociatorImpl* associator,
+ const std::string& tag, int64* sync_id) {
std::wstring tag_wide;
if (!UTF8ToWide(tag.c_str(), tag.length(), &tag_wide)) {
NOTREACHED() << "Unable to convert UTF8 to wide for string: " << tag;
@@ -75,7 +70,7 @@
}
sync_api::WriteTransaction trans(
- ModelAssociatorImpl::sync_service()->backend()->GetUserShareHandle());
+ associator->sync_service()->backend()->GetUserShareHandle());
sync_api::ReadNode root(&trans);
root.InitByRootLookup();
@@ -110,7 +105,7 @@
return true;
}
- ~TestModelAssociator() {}
+ ~TestModelAssociatorHelper() {}
};
class ProfileSyncServiceObserverMock : public ProfileSyncServiceObserver {
« no previous file with comments | « chrome/browser/sync/profile_sync_service_unittest.cc ('k') | chrome/browser/sync/unrecoverable_error_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698