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

Side by Side Diff: chrome/browser/extensions/extension_service_unittest.cc

Issue 508513002: Remove implicit conversions from scoped_refptr to T* in chrome/browser/extensions/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Two more Created 6 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 <algorithm> 5 #include <algorithm>
6 #include <set> 6 #include <set>
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/at_exit.h" 9 #include "base/at_exit.h"
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 1106 matching lines...) Expand 10 before | Expand all | Expand 10 after
1117 ASSERT_TRUE(base::PathExists(crx_path)) 1117 ASSERT_TRUE(base::PathExists(crx_path))
1118 << "Path does not exist: "<< crx_path.value().c_str(); 1118 << "Path does not exist: "<< crx_path.value().c_str();
1119 scoped_refptr<CrxInstaller> installer( 1119 scoped_refptr<CrxInstaller> installer(
1120 CrxInstaller::CreateSilent(service())); 1120 CrxInstaller::CreateSilent(service()));
1121 installer->set_creation_flags(creation_flags); 1121 installer->set_creation_flags(creation_flags);
1122 if (!(creation_flags & Extension::WAS_INSTALLED_BY_DEFAULT)) 1122 if (!(creation_flags & Extension::WAS_INSTALLED_BY_DEFAULT))
1123 installer->set_allow_silent_install(true); 1123 installer->set_allow_silent_install(true);
1124 1124
1125 content::WindowedNotificationObserver observer( 1125 content::WindowedNotificationObserver observer(
1126 extensions::NOTIFICATION_CRX_INSTALLER_DONE, 1126 extensions::NOTIFICATION_CRX_INSTALLER_DONE,
1127 content::Source<extensions::CrxInstaller>(installer)); 1127 content::Source<extensions::CrxInstaller>(installer.get()));
1128 1128
1129 installer->InstallCrx(crx_path); 1129 installer->InstallCrx(crx_path);
1130 1130
1131 observer.Wait(); 1131 observer.Wait();
1132 } 1132 }
1133 1133
1134 size_t expected_extensions_count_; 1134 size_t expected_extensions_count_;
1135 content::NotificationRegistrar registrar_; 1135 content::NotificationRegistrar registrar_;
1136 }; 1136 };
1137 1137
(...skipping 6015 matching lines...) Expand 10 before | Expand all | Expand 10 after
7153 7153
7154 service()->Observe(chrome::NOTIFICATION_PROFILE_DESTRUCTION_STARTED, 7154 service()->Observe(chrome::NOTIFICATION_PROFILE_DESTRUCTION_STARTED,
7155 content::Source<Profile>(profile()), 7155 content::Source<Profile>(profile()),
7156 content::NotificationService::NoDetails()); 7156 content::NotificationService::NoDetails());
7157 EXPECT_EQ(UnloadedExtensionInfo::REASON_PROFILE_SHUTDOWN, unloaded_reason_); 7157 EXPECT_EQ(UnloadedExtensionInfo::REASON_PROFILE_SHUTDOWN, unloaded_reason_);
7158 EXPECT_EQ(0u, registry()->enabled_extensions().size()); 7158 EXPECT_EQ(0u, registry()->enabled_extensions().size());
7159 EXPECT_EQ(0u, registry()->disabled_extensions().size()); 7159 EXPECT_EQ(0u, registry()->disabled_extensions().size());
7160 EXPECT_EQ(0u, registry()->terminated_extensions().size()); 7160 EXPECT_EQ(0u, registry()->terminated_extensions().size());
7161 EXPECT_EQ(0u, registry()->blacklisted_extensions().size()); 7161 EXPECT_EQ(0u, registry()->blacklisted_extensions().size());
7162 } 7162 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698