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/utf_string_conversions.h" | 5 #include "base/utf_string_conversions.h" |
6 #include "chrome/browser/automation/automation_util.h" | 6 #include "chrome/browser/automation/automation_util.h" |
7 #include "chrome/browser/extensions/extension_apitest.h" | 7 #include "chrome/browser/extensions/extension_apitest.h" |
8 #include "chrome/browser/extensions/extension_host.h" | 8 #include "chrome/browser/extensions/extension_host.h" |
9 #include "chrome/browser/extensions/extension_process_manager.h" | 9 #include "chrome/browser/extensions/extension_process_manager.h" |
10 #include "chrome/browser/extensions/extension_service.h" | 10 #include "chrome/browser/extensions/extension_service.h" |
(...skipping 12 matching lines...) Expand all Loading... |
23 #include "net/base/mock_host_resolver.h" | 23 #include "net/base/mock_host_resolver.h" |
24 | 24 |
25 using content::NavigationController; | 25 using content::NavigationController; |
26 using content::WebContents; | 26 using content::WebContents; |
27 | 27 |
28 namespace { | 28 namespace { |
29 | 29 |
30 class ProcessManagementTest : public ExtensionBrowserTest { | 30 class ProcessManagementTest : public ExtensionBrowserTest { |
31 private: | 31 private: |
32 // This is needed for testing isolated apps, which are still experimental. | 32 // This is needed for testing isolated apps, which are still experimental. |
33 virtual void SetUpCommandLine(CommandLine* command_line) { | 33 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { |
34 ExtensionBrowserTest::SetUpCommandLine(command_line); | 34 ExtensionBrowserTest::SetUpCommandLine(command_line); |
35 command_line->AppendSwitch(switches::kEnableExperimentalExtensionApis); | 35 command_line->AppendSwitch(switches::kEnableExperimentalExtensionApis); |
36 } | 36 } |
37 }; | 37 }; |
38 | 38 |
39 } // namespace | 39 } // namespace |
40 | 40 |
41 | 41 |
42 // TODO(nasko): crbug.com/173137 | 42 // TODO(nasko): crbug.com/173137 |
43 #if defined(OS_WIN) | 43 #if defined(OS_WIN) |
(...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
235 | 235 |
236 // We've loaded 5 extensions with background pages, 1 extension without | 236 // We've loaded 5 extensions with background pages, 1 extension without |
237 // background page, and one isolated app. We expect only 2 unique processes | 237 // background page, and one isolated app. We expect only 2 unique processes |
238 // hosting those extensions. | 238 // hosting those extensions. |
239 ExtensionService* service = | 239 ExtensionService* service = |
240 extensions::ExtensionSystem::Get(profile)->extension_service(); | 240 extensions::ExtensionSystem::Get(profile)->extension_service(); |
241 | 241 |
242 EXPECT_GE((size_t) 6, service->process_map()->size()); | 242 EXPECT_GE((size_t) 6, service->process_map()->size()); |
243 EXPECT_EQ((size_t) 2, process_ids.size()); | 243 EXPECT_EQ((size_t) 2, process_ids.size()); |
244 } | 244 } |
OLD | NEW |