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/files/file_path.h" | 5 #include "base/files/file_path.h" |
6 #include "base/scoped_observer.h" | 6 #include "base/scoped_observer.h" |
7 #include "base/strings/utf_string_conversions.h" | 7 #include "base/strings/utf_string_conversions.h" |
8 #include "chrome/browser/bookmarks/bookmark_model_factory.h" | 8 #include "chrome/browser/bookmarks/bookmark_model_factory.h" |
9 #include "chrome/browser/extensions/browser_action_test_util.h" | 9 #include "chrome/browser/extensions/browser_action_test_util.h" |
10 #include "chrome/browser/extensions/extension_apitest.h" | 10 #include "chrome/browser/extensions/extension_apitest.h" |
11 #include "chrome/browser/extensions/lazy_background_page_test_util.h" | 11 #include "chrome/browser/extensions/lazy_background_page_test_util.h" |
12 #include "chrome/browser/profiles/profile.h" | 12 #include "chrome/browser/profiles/profile.h" |
13 #include "chrome/browser/ui/browser.h" | 13 #include "chrome/browser/ui/browser.h" |
14 #include "chrome/browser/ui/browser_window.h" | 14 #include "chrome/browser/ui/browser_window.h" |
15 #include "chrome/browser/ui/location_bar/location_bar.h" | 15 #include "chrome/browser/ui/location_bar/location_bar.h" |
16 #include "chrome/browser/ui/tabs/tab_strip_model.h" | 16 #include "chrome/browser/ui/tabs/tab_strip_model.h" |
17 #include "chrome/common/url_constants.h" | 17 #include "chrome/common/url_constants.h" |
18 #include "chrome/test/base/ui_test_utils.h" | 18 #include "chrome/test/base/ui_test_utils.h" |
19 #include "components/app_modal_dialogs/app_modal_dialog.h" | 19 #include "components/app_modal/app_modal_dialog.h" |
20 #include "components/bookmarks/browser/bookmark_model.h" | 20 #include "components/bookmarks/browser/bookmark_model.h" |
21 #include "components/bookmarks/browser/bookmark_utils.h" | 21 #include "components/bookmarks/browser/bookmark_utils.h" |
22 #include "components/bookmarks/test/bookmark_test_helpers.h" | 22 #include "components/bookmarks/test/bookmark_test_helpers.h" |
23 #include "content/public/browser/web_contents.h" | 23 #include "content/public/browser/web_contents.h" |
24 #include "content/public/test/browser_test_utils.h" | 24 #include "content/public/test/browser_test_utils.h" |
25 #include "extensions/browser/extension_host.h" | 25 #include "extensions/browser/extension_host.h" |
26 #include "extensions/browser/extension_registry.h" | 26 #include "extensions/browser/extension_registry.h" |
27 #include "extensions/browser/extension_registry_observer.h" | 27 #include "extensions/browser/extension_registry_observer.h" |
28 #include "extensions/browser/process_manager.h" | 28 #include "extensions/browser/process_manager.h" |
29 #include "extensions/common/extension.h" | 29 #include "extensions/common/extension.h" |
(...skipping 530 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
560 | 560 |
561 // Tests that the lazy background page will be unloaded if the onSuspend event | 561 // Tests that the lazy background page will be unloaded if the onSuspend event |
562 // handler calls an API function such as chrome.storage.local.set(). | 562 // handler calls an API function such as chrome.storage.local.set(). |
563 // See: http://crbug.com/296834 | 563 // See: http://crbug.com/296834 |
564 IN_PROC_BROWSER_TEST_F(LazyBackgroundPageApiTest, OnSuspendUseStorageApi) { | 564 IN_PROC_BROWSER_TEST_F(LazyBackgroundPageApiTest, OnSuspendUseStorageApi) { |
565 EXPECT_TRUE(LoadExtensionAndWait("on_suspend")); | 565 EXPECT_TRUE(LoadExtensionAndWait("on_suspend")); |
566 } | 566 } |
567 | 567 |
568 // TODO: background page with timer. | 568 // TODO: background page with timer. |
569 // TODO: background page that interacts with popup. | 569 // TODO: background page that interacts with popup. |
OLD | NEW |