OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/task_manager/task_manager.h" | 5 #include "chrome/browser/task_manager/task_manager.h" |
6 | 6 |
7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
8 #include "base/file_path.h" | 8 #include "base/file_path.h" |
9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
10 #include "chrome/browser/background_contents_service.h" | 10 #include "chrome/browser/background_contents_service.h" |
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
289 | 289 |
290 EXPECT_TRUE(model()->GetResourceExtension(0) == NULL); | 290 EXPECT_TRUE(model()->GetResourceExtension(0) == NULL); |
291 EXPECT_TRUE(model()->GetResourceExtension(1) == NULL); | 291 EXPECT_TRUE(model()->GetResourceExtension(1) == NULL); |
292 ASSERT_TRUE(model()->GetResourceExtension(2) != NULL); | 292 ASSERT_TRUE(model()->GetResourceExtension(2) != NULL); |
293 | 293 |
294 // Kill the extension process and make sure we notice it. | 294 // Kill the extension process and make sure we notice it. |
295 TaskManager::GetInstance()->KillProcess(2); | 295 TaskManager::GetInstance()->KillProcess(2); |
296 WaitForResourceChange(2); | 296 WaitForResourceChange(2); |
297 } | 297 } |
298 | 298 |
299 IN_PROC_BROWSER_TEST_F(TaskManagerBrowserTest, KillExtensionAndReload) { | 299 // Disabled, http://crbug.com/66957. |
| 300 IN_PROC_BROWSER_TEST_F(TaskManagerBrowserTest, |
| 301 DISABLED_KillExtensionAndReload) { |
300 // Show the task manager. This populates the model, and helps with debugging | 302 // Show the task manager. This populates the model, and helps with debugging |
301 // (you see the task manager). | 303 // (you see the task manager). |
302 browser()->window()->ShowTaskManager(); | 304 browser()->window()->ShowTaskManager(); |
303 | 305 |
304 ASSERT_TRUE(LoadExtension( | 306 ASSERT_TRUE(LoadExtension( |
305 test_data_dir_.AppendASCII("common").AppendASCII("background_page"))); | 307 test_data_dir_.AppendASCII("common").AppendASCII("background_page"))); |
306 | 308 |
307 // Wait until we see the loaded extension in the task manager (the three | 309 // Wait until we see the loaded extension in the task manager (the three |
308 // resources are: the browser process, New Tab Page, and the extension). | 310 // resources are: the browser process, New Tab Page, and the extension). |
309 WaitForResourceChange(3); | 311 WaitForResourceChange(3); |
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
382 WaitForResourceChange(3); | 384 WaitForResourceChange(3); |
383 | 385 |
384 // Check that we get some value for the cache columns. | 386 // Check that we get some value for the cache columns. |
385 DCHECK_NE(model()->GetResourceWebCoreImageCacheSize(2), | 387 DCHECK_NE(model()->GetResourceWebCoreImageCacheSize(2), |
386 l10n_util::GetStringUTF16(IDS_TASK_MANAGER_NA_CELL_TEXT)); | 388 l10n_util::GetStringUTF16(IDS_TASK_MANAGER_NA_CELL_TEXT)); |
387 DCHECK_NE(model()->GetResourceWebCoreScriptsCacheSize(2), | 389 DCHECK_NE(model()->GetResourceWebCoreScriptsCacheSize(2), |
388 l10n_util::GetStringUTF16(IDS_TASK_MANAGER_NA_CELL_TEXT)); | 390 l10n_util::GetStringUTF16(IDS_TASK_MANAGER_NA_CELL_TEXT)); |
389 DCHECK_NE(model()->GetResourceWebCoreCSSCacheSize(2), | 391 DCHECK_NE(model()->GetResourceWebCoreCSSCacheSize(2), |
390 l10n_util::GetStringUTF16(IDS_TASK_MANAGER_NA_CELL_TEXT)); | 392 l10n_util::GetStringUTF16(IDS_TASK_MANAGER_NA_CELL_TEXT)); |
391 } | 393 } |
OLD | NEW |