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

Side by Side Diff: chrome/browser/sync/test/integration/bookmarks_helper.cc

Issue 1882243004: Convert //chrome/browser/sync from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address feedback Created 4 years, 8 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 (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/bookmarks_helper.h" 5 #include "chrome/browser/sync/test/integration/bookmarks_helper.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <set> 9 #include <set>
10 #include <vector> 10 #include <vector>
(...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after
313 profiles_which_need_to_wait.push_back( 313 profiles_which_need_to_wait.push_back(
314 sync_datatype_helper::test()->GetProfile(i)); 314 sync_datatype_helper::test()->GetProfile(i));
315 315
316 for (size_t i = 0; i < profiles_which_need_to_wait.size(); ++i) { 316 for (size_t i = 0; i < profiles_which_need_to_wait.size(); ++i) {
317 Profile* profile = profiles_which_need_to_wait[i]; 317 Profile* profile = profiles_which_need_to_wait[i];
318 history::HistoryService* history_service = 318 history::HistoryService* history_service =
319 HistoryServiceFactory::GetForProfileWithoutCreating(profile); 319 HistoryServiceFactory::GetForProfileWithoutCreating(profile);
320 base::WaitableEvent done(false, false); 320 base::WaitableEvent done(false, false);
321 base::CancelableTaskTracker task_tracker; 321 base::CancelableTaskTracker task_tracker;
322 history_service->ScheduleDBTask( 322 history_service->ScheduleDBTask(
323 scoped_ptr<history::HistoryDBTask>( 323 std::unique_ptr<history::HistoryDBTask>(new HistoryEmptyTask(&done)),
324 new HistoryEmptyTask(&done)),
325 &task_tracker); 324 &task_tracker);
326 done.Wait(); 325 done.Wait();
327 } 326 }
328 // Wait such that any notifications broadcast from one of the history threads 327 // Wait such that any notifications broadcast from one of the history threads
329 // to the UI thread are processed. 328 // to the UI thread are processed.
330 content::RunAllPendingInMessageLoop(); 329 content::RunAllPendingInMessageLoop();
331 } 330 }
332 331
333 // Checks if the favicon in |node_a| from |model_a| matches that of |node_b| 332 // Checks if the favicon in |node_a| from |model_a| matches that of |node_b|
334 // from |model_b|. Returns true if they match. 333 // from |model_b|. Returns true if they match.
(...skipping 666 matching lines...) Expand 10 before | Expand all | Expand 10 after
1001 1000
1002 std::string IndexedSubfolderName(int i) { 1001 std::string IndexedSubfolderName(int i) {
1003 return base::StringPrintf("Subfolder Name %d", i); 1002 return base::StringPrintf("Subfolder Name %d", i);
1004 } 1003 }
1005 1004
1006 std::string IndexedSubsubfolderName(int i) { 1005 std::string IndexedSubsubfolderName(int i) {
1007 return base::StringPrintf("Subsubfolder Name %d", i); 1006 return base::StringPrintf("Subsubfolder Name %d", i);
1008 } 1007 }
1009 1008
1010 } // namespace bookmarks_helper 1009 } // namespace bookmarks_helper
OLDNEW
« no previous file with comments | « chrome/browser/sync/sync_ui_util_unittest.cc ('k') | chrome/browser/sync/test/integration/extension_settings_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698