OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 "chrome/common/extensions/extension_message_bundle.h" | 5 #include "chrome/common/extensions/extension_message_bundle.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "app/l10n_util.h" | |
11 #include "base/i18n/rtl.h" | 10 #include "base/i18n/rtl.h" |
12 #include "base/linked_ptr.h" | 11 #include "base/linked_ptr.h" |
13 #include "base/scoped_ptr.h" | 12 #include "base/scoped_ptr.h" |
14 #include "base/string_util.h" | 13 #include "base/string_util.h" |
15 #include "base/values.h" | 14 #include "base/values.h" |
16 #include "chrome/common/extensions/extension_constants.h" | 15 #include "chrome/common/extensions/extension_constants.h" |
17 #include "chrome/common/extensions/extension_error_utils.h" | 16 #include "chrome/common/extensions/extension_error_utils.h" |
18 #include "chrome/common/extensions/extension_l10n_util.h" | 17 #include "chrome/common/extensions/extension_l10n_util.h" |
19 #include "testing/gtest/include/gtest/gtest.h" | 18 #include "testing/gtest/include/gtest/gtest.h" |
20 | 19 |
(...skipping 396 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
417 // Store a map for given id. | 416 // Store a map for given id. |
418 L10nMessagesMap messages; | 417 L10nMessagesMap messages; |
419 messages.insert(std::make_pair("message_name", "message_value")); | 418 messages.insert(std::make_pair("message_name", "message_value")); |
420 (*GetExtensionToL10nMessagesMap())[extension_id] = messages; | 419 (*GetExtensionToL10nMessagesMap())[extension_id] = messages; |
421 | 420 |
422 L10nMessagesMap* map = GetL10nMessagesMap(extension_id); | 421 L10nMessagesMap* map = GetL10nMessagesMap(extension_id); |
423 ASSERT_TRUE(NULL != map); | 422 ASSERT_TRUE(NULL != map); |
424 EXPECT_EQ(1U, map->size()); | 423 EXPECT_EQ(1U, map->size()); |
425 EXPECT_EQ("message_value", (*map)["message_name"]); | 424 EXPECT_EQ("message_value", (*map)["message_name"]); |
426 } | 425 } |
OLD | NEW |