Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3728)

Unified Diff: chrome/common/extensions/manifest_tests/extension_manifests_launch_unittest.cc

Issue 15984016: Call scoped_refptr<T>::get() rather than relying on implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/common/extensions/manifest_tests/extension_manifests_launch_unittest.cc
diff --git a/chrome/common/extensions/manifest_tests/extension_manifests_launch_unittest.cc b/chrome/common/extensions/manifest_tests/extension_manifests_launch_unittest.cc
index 456122e956ee7de5c4af4505645f5020d07e8eb1..9a63f61c6d46c6faa9f70f27f8dfcbcea71b07e8 100644
--- a/chrome/common/extensions/manifest_tests/extension_manifests_launch_unittest.cc
+++ b/chrome/common/extensions/manifest_tests/extension_manifests_launch_unittest.cc
@@ -24,21 +24,21 @@ TEST_F(AppLaunchManifestTest, AppLaunchContainer) {
extension = LoadAndExpectSuccess("launch_tab.json");
EXPECT_EQ(extension_misc::LAUNCH_TAB,
- AppLaunchInfo::GetLaunchContainer(extension));
+ AppLaunchInfo::GetLaunchContainer(extension.get()));
extension = LoadAndExpectSuccess("launch_panel.json");
EXPECT_EQ(extension_misc::LAUNCH_PANEL,
- AppLaunchInfo::GetLaunchContainer(extension));
+ AppLaunchInfo::GetLaunchContainer(extension.get()));
extension = LoadAndExpectSuccess("launch_default.json");
EXPECT_EQ(extension_misc::LAUNCH_TAB,
- AppLaunchInfo::GetLaunchContainer(extension));
+ AppLaunchInfo::GetLaunchContainer(extension.get()));
extension = LoadAndExpectSuccess("launch_width.json");
- EXPECT_EQ(640, AppLaunchInfo::GetLaunchWidth(extension));
+ EXPECT_EQ(640, AppLaunchInfo::GetLaunchWidth(extension.get()));
extension = LoadAndExpectSuccess("launch_height.json");
- EXPECT_EQ(480, AppLaunchInfo::GetLaunchHeight(extension));
+ EXPECT_EQ(480, AppLaunchInfo::GetLaunchHeight(extension.get()));
Testcase testcases[] = {
Testcase("launch_window.json", errors::kInvalidLaunchContainer),
@@ -110,11 +110,11 @@ TEST_F(AppLaunchManifestTest, AppLaunchURL) {
scoped_refptr<Extension> extension;
extension = LoadAndExpectSuccess("launch_local_path.json");
EXPECT_EQ(extension->url().spec() + "launch.html",
- AppLaunchInfo::GetFullLaunchURL(extension).spec());
+ AppLaunchInfo::GetFullLaunchURL(extension.get()).spec());
extension = LoadAndExpectSuccess("launch_local_path_localized.json");
EXPECT_EQ(extension->url().spec() + "launch.html",
- AppLaunchInfo::GetFullLaunchURL(extension).spec());
+ AppLaunchInfo::GetFullLaunchURL(extension.get()).spec());
LoadAndExpectError("launch_web_url_relative.json",
ErrorUtils::FormatErrorMessage(
@@ -123,10 +123,10 @@ TEST_F(AppLaunchManifestTest, AppLaunchURL) {
extension = LoadAndExpectSuccess("launch_web_url_absolute.json");
EXPECT_EQ(GURL("http://www.google.com/launch.html"),
- AppLaunchInfo::GetFullLaunchURL(extension));
+ AppLaunchInfo::GetFullLaunchURL(extension.get()));
extension = LoadAndExpectSuccess("launch_web_url_localized.json");
EXPECT_EQ(GURL("http://www.google.com/launch.html"),
- AppLaunchInfo::GetFullLaunchURL(extension));
+ AppLaunchInfo::GetFullLaunchURL(extension.get()));
}
} // namespace extensions

Powered by Google App Engine
This is Rietveld 408576698