OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 <limits> | 5 #include <limits> |
6 | 6 |
7 #include "base/scoped_ptr.h" | 7 #include "base/memory/scoped_ptr.h" |
8 #include "base/string16.h" | 8 #include "base/string16.h" |
9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
10 #include "base/values.h" | 10 #include "base/values.h" |
11 #include "testing/gtest/include/gtest/gtest.h" | 11 #include "testing/gtest/include/gtest/gtest.h" |
12 | 12 |
13 class ValuesTest : public testing::Test { | 13 class ValuesTest : public testing::Test { |
14 }; | 14 }; |
15 | 15 |
16 TEST_F(ValuesTest, Basic) { | 16 TEST_F(ValuesTest, Basic) { |
17 // Test basic dictionary getting/setting | 17 // Test basic dictionary getting/setting |
(...skipping 661 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
679 EXPECT_TRUE(res_sub_dict->GetString("sub_base_key", &sub_base_key_value)); | 679 EXPECT_TRUE(res_sub_dict->GetString("sub_base_key", &sub_base_key_value)); |
680 EXPECT_EQ("sub_base_key_value_base", sub_base_key_value); // Preserved. | 680 EXPECT_EQ("sub_base_key_value_base", sub_base_key_value); // Preserved. |
681 std::string sub_collide_key_value; | 681 std::string sub_collide_key_value; |
682 EXPECT_TRUE(res_sub_dict->GetString("sub_collide_key", | 682 EXPECT_TRUE(res_sub_dict->GetString("sub_collide_key", |
683 &sub_collide_key_value)); | 683 &sub_collide_key_value)); |
684 EXPECT_EQ("sub_collide_key_value_merge", sub_collide_key_value); // Replaced. | 684 EXPECT_EQ("sub_collide_key_value_merge", sub_collide_key_value); // Replaced. |
685 std::string sub_merge_key_value; | 685 std::string sub_merge_key_value; |
686 EXPECT_TRUE(res_sub_dict->GetString("sub_merge_key", &sub_merge_key_value)); | 686 EXPECT_TRUE(res_sub_dict->GetString("sub_merge_key", &sub_merge_key_value)); |
687 EXPECT_EQ("sub_merge_key_value_merge", sub_merge_key_value); // Merged in. | 687 EXPECT_EQ("sub_merge_key_value_merge", sub_merge_key_value); // Merged in. |
688 } | 688 } |
OLD | NEW |