| 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/command_line.h" | 5 #include "base/command_line.h" |
| 6 #include "chrome/common/extensions/extension.h" | 6 #include "chrome/common/extensions/extension.h" |
| 7 #include "chrome/common/extensions/extension_manifest_constants.h" | 7 #include "chrome/common/extensions/extension_manifest_constants.h" |
| 8 #include "chrome/common/extensions/manifest.h" | |
| 9 #include "chrome/common/extensions/manifest_tests/extension_manifest_test.h" | 8 #include "chrome/common/extensions/manifest_tests/extension_manifest_test.h" |
| 10 #include "chrome/common/extensions/permissions/permissions_data.h" | 9 #include "chrome/common/extensions/permissions/permissions_data.h" |
| 10 #include "extensions/common/manifest.h" |
| 11 #include "extensions/common/switches.h" | 11 #include "extensions/common/switches.h" |
| 12 #include "testing/gtest/include/gtest/gtest.h" | 12 #include "testing/gtest/include/gtest/gtest.h" |
| 13 | 13 |
| 14 namespace errors = extension_manifest_errors; | 14 namespace errors = extension_manifest_errors; |
| 15 | 15 |
| 16 namespace extensions { | 16 namespace extensions { |
| 17 | 17 |
| 18 TEST_F(ExtensionManifestTest, ChromeURLPermissionInvalid) { | 18 TEST_F(ExtensionManifestTest, ChromeURLPermissionInvalid) { |
| 19 LoadAndExpectError("permission_chrome_url_invalid.json", | 19 LoadAndExpectError("permission_chrome_url_invalid.json", |
| 20 errors::kInvalidPermissionScheme); | 20 errors::kInvalidPermissionScheme); |
| (...skipping 18 matching lines...) Expand all Loading... |
| 39 errors::kInvalidPermissionScheme); | 39 errors::kInvalidPermissionScheme); |
| 40 std::string error; | 40 std::string error; |
| 41 LoadExtension(Manifest("permission_chrome_resources_url.json"), | 41 LoadExtension(Manifest("permission_chrome_resources_url.json"), |
| 42 &error, | 42 &error, |
| 43 extensions::Manifest::COMPONENT, | 43 extensions::Manifest::COMPONENT, |
| 44 Extension::NO_FLAGS); | 44 Extension::NO_FLAGS); |
| 45 EXPECT_EQ("", error); | 45 EXPECT_EQ("", error); |
| 46 } | 46 } |
| 47 | 47 |
| 48 } // namespace extensions | 48 } // namespace extensions |
| OLD | NEW |