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

Unified Diff: content/browser/indexed_db/list_set_unittest.cc

Issue 2233153002: IndexedDB: WrapUnique(new T(args..)) -> MakeUnique<T>(args...) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Review feedback Created 4 years, 4 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: content/browser/indexed_db/list_set_unittest.cc
diff --git a/content/browser/indexed_db/list_set_unittest.cc b/content/browser/indexed_db/list_set_unittest.cc
index 293330da5ca7887ee73a48d2aa01f4012dae7f30..642486640feccc8d5e084cdf0c54e4629fc6a503 100644
--- a/content/browser/indexed_db/list_set_unittest.cc
+++ b/content/browser/indexed_db/list_set_unittest.cc
@@ -6,6 +6,7 @@
#include <memory>
+#include "base/memory/ptr_util.h"
#include "base/memory/ref_counted.h"
#include "testing/gtest/include/gtest/gtest.h"
@@ -148,9 +149,9 @@ TEST(ListSetTest, ListSetObject) {
}
TEST(ListSetTest, ListSetPointer) {
- std::unique_ptr<Wrapped<int>> w0(new Wrapped<int>(0));
- std::unique_ptr<Wrapped<int>> w1(new Wrapped<int>(1));
- std::unique_ptr<Wrapped<int>> w2(new Wrapped<int>(2));
+ std::unique_ptr<Wrapped<int>> w0 = base::MakeUnique<Wrapped<int>>(0);
+ std::unique_ptr<Wrapped<int>> w1 = base::MakeUnique<Wrapped<int>>(1);
+ std::unique_ptr<Wrapped<int>> w2 = base::MakeUnique<Wrapped<int>>(2);
list_set<Wrapped<int>*> set;
EXPECT_EQ(0u, set.size());

Powered by Google App Engine
This is Rietveld 408576698