diff options
Diffstat (limited to 'third_party/chromium/base/json/json_reader_unittest.cc')
-rw-r--r-- | third_party/chromium/base/json/json_reader_unittest.cc | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/third_party/chromium/base/json/json_reader_unittest.cc b/third_party/chromium/base/json/json_reader_unittest.cc index 2bfd10e..b1ad46e 100644 --- a/third_party/chromium/base/json/json_reader_unittest.cc +++ b/third_party/chromium/base/json/json_reader_unittest.cc @@ -7,10 +7,10 @@ #include <stddef.h> #include <gtest/gtest.h> +#include <memory> #include "base/logging.h" #include "base/macros.h" -#include "base/memory/scoped_ptr.h" #include "base/strings/string_piece.h" #include "base/strings/utf_string_conversion_utils.h" #include "base/values.h" @@ -20,7 +20,7 @@ namespace base { TEST(JSONReaderTest, Reading) { // some whitespace checking - scoped_ptr<Value> root = JSONReader().ReadToValue(" null "); + std::unique_ptr<Value> root = JSONReader().ReadToValue(" null "); ASSERT_TRUE(root.get()); EXPECT_TRUE(root->IsType(Value::TYPE_NULL)); @@ -249,7 +249,7 @@ TEST(JSONReaderTest, Reading) { EXPECT_EQ(3U, list->GetSize()); // Test with trailing comma. Should be parsed the same as above. - scoped_ptr<Value> root2 = + std::unique_ptr<Value> root2 = JSONReader::Read("[true, false, null, ]", JSON_ALLOW_TRAILING_COMMAS); EXPECT_TRUE(root->Equals(root2.get())); @@ -543,15 +543,15 @@ TEST(JSONReaderTest, Reading) { // Tests that the root of a JSON object can be deleted safely while its // children outlive it. TEST(JSONReaderTest, StringOptimizations) { - scoped_ptr<Value> dict_literal_0; - scoped_ptr<Value> dict_literal_1; - scoped_ptr<Value> dict_string_0; - scoped_ptr<Value> dict_string_1; - scoped_ptr<Value> list_value_0; - scoped_ptr<Value> list_value_1; + std::unique_ptr<Value> dict_literal_0; + std::unique_ptr<Value> dict_literal_1; + std::unique_ptr<Value> dict_string_0; + std::unique_ptr<Value> dict_string_1; + std::unique_ptr<Value> list_value_0; + std::unique_ptr<Value> list_value_1; { - scoped_ptr<Value> root = JSONReader::Read( + std::unique_ptr<Value> root = JSONReader::Read( "{" " \"test\": {" " \"foo\": true," |