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

Unified Diff: base/debug/activity_analyzer_unittest.cc

Issue 2258713003: Re-write many calls to WrapUnique() with MakeUnique() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 3 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
« no previous file with comments | « base/debug/activity_analyzer.cc ('k') | base/debug/activity_tracker.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/debug/activity_analyzer_unittest.cc
diff --git a/base/debug/activity_analyzer_unittest.cc b/base/debug/activity_analyzer_unittest.cc
index 6fb6b3f436089b791f4200cee07b43a2e1729639..953a52f02d5cafce56fe68828f1babafa1dd501d 100644
--- a/base/debug/activity_analyzer_unittest.cc
+++ b/base/debug/activity_analyzer_unittest.cc
@@ -61,7 +61,7 @@ class ActivityAnalyzerTest : public testing::Test {
std::unique_ptr<ThreadActivityTracker> CreateActivityTracker() {
std::unique_ptr<char[]> memory(new char[kStackSize]);
- return WrapUnique(new TestActivityTracker(std::move(memory), kStackSize));
+ return MakeUnique<TestActivityTracker>(std::move(memory), kStackSize);
}
static void DoNothing() {}
@@ -142,9 +142,8 @@ TEST_F(ActivityAnalyzerTest, GlobalAnalyzerConstruction) {
PersistentMemoryAllocator* allocator =
GlobalActivityTracker::Get()->allocator();
- GlobalActivityAnalyzer analyzer(WrapUnique(
- new PersistentMemoryAllocator(const_cast<void*>(allocator->data()),
- allocator->size(), 0, 0, "", true)));
+ GlobalActivityAnalyzer analyzer(MakeUnique<PersistentMemoryAllocator>(
+ const_cast<void*>(allocator->data()), allocator->size(), 0, 0, "", true));
// The only thread at thois point is the test thread.
ThreadActivityAnalyzer* ta1 = analyzer.GetFirstAnalyzer();
« no previous file with comments | « base/debug/activity_analyzer.cc ('k') | base/debug/activity_tracker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698