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

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

Issue 671763002: Extract ProcessManager from ExtensionSystem. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased. Created 6 years, 1 month 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) 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 "chrome/browser/browser_process.h" 5 #include "chrome/browser/browser_process.h"
6 #include "chrome/browser/extensions/extension_browsertest.h" 6 #include "chrome/browser/extensions/extension_browsertest.h"
7 #include "chrome/browser/extensions/extension_service.h" 7 #include "chrome/browser/extensions/extension_service.h"
8 #include "chrome/browser/notifications/notification.h" 8 #include "chrome/browser/notifications/notification.h"
9 #include "chrome/browser/notifications/notification_delegate.h" 9 #include "chrome/browser/notifications/notification_delegate.h"
10 #include "chrome/browser/notifications/notification_ui_manager.h" 10 #include "chrome/browser/notifications/notification_ui_manager.h"
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 virtual void AcceptNotification(size_t index) = 0; 46 virtual void AcceptNotification(size_t index) = 0;
47 virtual void CancelNotification(size_t index) = 0; 47 virtual void CancelNotification(size_t index) = 0;
48 virtual size_t CountBalloons() = 0; 48 virtual size_t CountBalloons() = 0;
49 49
50 ExtensionService* GetExtensionService() { 50 ExtensionService* GetExtensionService() {
51 return extensions::ExtensionSystem::Get(browser()->profile())-> 51 return extensions::ExtensionSystem::Get(browser()->profile())->
52 extension_service(); 52 extension_service();
53 } 53 }
54 54
55 extensions::ProcessManager* GetProcessManager() { 55 extensions::ProcessManager* GetProcessManager() {
56 return extensions::ExtensionSystem::Get(browser()->profile())-> 56 return extensions::ProcessManager::Get(browser()->profile());
57 process_manager();
58 } 57 }
59 58
60 ExtensionRegistry* GetExtensionRegistry() { 59 ExtensionRegistry* GetExtensionRegistry() {
61 return ExtensionRegistry::Get(browser()->profile()); 60 return ExtensionRegistry::Get(browser()->profile());
62 } 61 }
63 62
64 size_t GetEnabledExtensionCount() { 63 size_t GetEnabledExtensionCount() {
65 return GetExtensionRegistry()->enabled_extensions().size(); 64 return GetExtensionRegistry()->enabled_extensions().size();
66 } 65 }
67 66
(...skipping 485 matching lines...) Expand 10 before | Expand all | Expand 10 after
553 GetController())); 552 GetController()));
554 chrome::Reload(browser(), CURRENT_TAB); 553 chrome::Reload(browser(), CURRENT_TAB);
555 observer.Wait(); 554 observer.Wait();
556 } 555 }
557 // Extension should now be loaded. 556 // Extension should now be loaded.
558 SCOPED_TRACE("after reloading the tab"); 557 SCOPED_TRACE("after reloading the tab");
559 CheckExtensionConsistency(first_extension_id_); 558 CheckExtensionConsistency(first_extension_id_);
560 ASSERT_EQ(count_before + 1, GetEnabledExtensionCount()); 559 ASSERT_EQ(count_before + 1, GetEnabledExtensionCount());
561 ASSERT_EQ(0U, CountBalloons()); 560 ASSERT_EQ(0U, CountBalloons());
562 } 561 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_bindings_apitest.cc ('k') | chrome/browser/extensions/extension_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698