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

Unified Diff: components/dom_distiller/core/page_features_unittest.cc

Issue 1879613003: Convert //components/dom_distiller from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/dom_distiller/core/page_features.cc ('k') | components/dom_distiller/core/task_tracker.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/dom_distiller/core/page_features_unittest.cc
diff --git a/components/dom_distiller/core/page_features_unittest.cc b/components/dom_distiller/core/page_features_unittest.cc
index eaea31e110732002ff692caeffccb9e2e8c6d58a..6d0bea34b80093f921816696808589021c2f74c3 100644
--- a/components/dom_distiller/core/page_features_unittest.cc
+++ b/components/dom_distiller/core/page_features_unittest.cc
@@ -6,13 +6,13 @@
#include <stddef.h>
+#include <memory>
#include <string>
#include <vector>
#include "base/files/file_util.h"
#include "base/json/json_reader.h"
#include "base/json/json_writer.h"
-#include "base/memory/scoped_ptr.h"
#include "base/path_service.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "url/gurl.h"
@@ -38,10 +38,10 @@ TEST(DomDistillerPageFeaturesTest, TestCalculateDerivedFeatures) {
"components/test/data/dom_distiller/derived_features.json"),
&expected_output_data));
- scoped_ptr<base::Value> input_json = base::JSONReader::Read(input_data);
+ std::unique_ptr<base::Value> input_json = base::JSONReader::Read(input_data);
ASSERT_TRUE(input_json);
- scoped_ptr<base::Value> expected_output_json =
+ std::unique_ptr<base::Value> expected_output_json =
base::JSONReader::Read(expected_output_data);
ASSERT_TRUE(expected_output_json);
@@ -74,7 +74,7 @@ TEST(DomDistillerPageFeaturesTest, TestCalculateDerivedFeatures) {
// JSON (and not a base::Value of the JSON itself)
std::string stringified_json;
ASSERT_TRUE(base::JSONWriter::Write(*core_features, &stringified_json));
- scoped_ptr<base::Value> stringified_value(
+ std::unique_ptr<base::Value> stringified_value(
new base::StringValue(stringified_json));
std::vector<double> derived(
CalculateDerivedFeaturesFromJSON(stringified_value.get()));
« no previous file with comments | « components/dom_distiller/core/page_features.cc ('k') | components/dom_distiller/core/task_tracker.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698