OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "base/file_path.h" | 5 #include "base/file_path.h" |
6 #include "base/file_util.h" | 6 #include "base/file_util.h" |
7 #include "base/memory/linked_ptr.h" | 7 #include "base/memory/linked_ptr.h" |
8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
9 #include "base/path_service.h" | 9 #include "base/path_service.h" |
10 #include "base/scoped_temp_dir.h" | 10 #include "base/scoped_temp_dir.h" |
11 #include "base/values.h" | 11 #include "base/values.h" |
12 #include "chrome/common/chrome_paths.h" | 12 #include "chrome/common/chrome_paths.h" |
13 #include "chrome/common/extensions/extension.h" | 13 #include "chrome/common/extensions/extension.h" |
14 #include "chrome/common/extensions/extension_manifest_constants.h" | 14 #include "chrome/common/extensions/extension_manifest_constants.h" |
15 #include "chrome/common/extensions/extension_l10n_util.h" | 15 #include "chrome/common/extensions/extension_l10n_util.h" |
16 #include "chrome/common/extensions/extension_message_bundle.h" | 16 #include "chrome/common/extensions/extension_message_bundle.h" |
17 #include "testing/gtest/include/gtest/gtest.h" | 17 #include "testing/gtest/include/gtest/gtest.h" |
18 #include "ui/base/l10n/l10n_util.h" | 18 #include "ui/base/l10n/l10n_util.h" |
19 | 19 |
| 20 using extensions::Extension; |
| 21 using extensions::ExtensionInfo; |
| 22 |
20 namespace errors = extension_manifest_errors; | 23 namespace errors = extension_manifest_errors; |
21 namespace keys = extension_manifest_keys; | 24 namespace keys = extension_manifest_keys; |
22 | 25 |
23 namespace { | 26 namespace { |
24 | 27 |
25 // crbug.com/108429: Crashing on Windows Vista bots. | 28 // crbug.com/108429: Crashing on Windows Vista bots. |
26 #if defined(OS_WIN) | 29 #if defined(OS_WIN) |
27 #define GetValidLocalesEmptyLocaleFolder \ | 30 #define GetValidLocalesEmptyLocaleFolder \ |
28 DISABLED_GetValidLocalesEmptyLocaleFolder | 31 DISABLED_GetValidLocalesEmptyLocaleFolder |
29 #define GetValidLocalesWithValidLocaleNoMessagesFile \ | 32 #define GetValidLocalesWithValidLocaleNoMessagesFile \ |
(...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
609 DictionaryValue manifest; | 612 DictionaryValue manifest; |
610 manifest.SetString(keys::kDefaultLocale, "en_US"); | 613 manifest.SetString(keys::kDefaultLocale, "en_US"); |
611 manifest.SetString(keys::kCurrentLocale, "sr"); | 614 manifest.SetString(keys::kCurrentLocale, "sr"); |
612 | 615 |
613 ExtensionInfo info(&manifest, "", FilePath(), Extension::LOAD); | 616 ExtensionInfo info(&manifest, "", FilePath(), Extension::LOAD); |
614 | 617 |
615 EXPECT_TRUE(extension_l10n_util::ShouldRelocalizeManifest(info)); | 618 EXPECT_TRUE(extension_l10n_util::ShouldRelocalizeManifest(info)); |
616 } | 619 } |
617 | 620 |
618 } // namespace | 621 } // namespace |
OLD | NEW |