Index: chrome/browser/extensions/lazy_background_page_apitest.cc |
diff --git a/chrome/browser/extensions/lazy_background_page_apitest.cc b/chrome/browser/extensions/lazy_background_page_apitest.cc |
index f6599d6119bc2c4f66826dc38f7552653799909e..439f3a2118d7abb7b2fd7da1c85c4782595310ea 100644 |
--- a/chrome/browser/extensions/lazy_background_page_apitest.cc |
+++ b/chrome/browser/extensions/lazy_background_page_apitest.cc |
@@ -571,6 +571,7 @@ IN_PROC_BROWSER_TEST_F(LazyBackgroundPageApiTest, EventDispatchToTab) { |
// when it is destroyed. |
IN_PROC_BROWSER_TEST_F(LazyBackgroundPageApiTest, UpdateExtensionsPage) { |
ui_test_utils::NavigateToURL(browser(), GURL(chrome::kChromeUIExtensionsURL)); |
+ auto* extensions_frame = browser()->tab_strip_model()->GetActiveWebContents(); |
Devlin
2017/06/13 18:04:21
this is a bit awkward - it's not a frame any more.
Dan Beam
2017/06/13 18:15:16
Done.
|
ResultCatcher catcher; |
base::FilePath extdir = test_data_dir_.AppendASCII("lazy_background_page"). |
@@ -597,13 +598,6 @@ IN_PROC_BROWSER_TEST_F(LazyBackgroundPageApiTest, UpdateExtensionsPage) { |
// Lazy Background Page has been shut down. |
EXPECT_FALSE(IsBackgroundPageAlive(last_loaded_extension_id())); |
- // Verify that extensions page shows that the lazy background page is |
- // inactive. |
- content::RenderFrameHost* frame = content::FrameMatchingPredicate( |
- browser()->tab_strip_model()->GetActiveWebContents(), |
- base::Bind(&content::FrameHasSourceUrl, |
- GURL(chrome::kChromeUIExtensionsFrameURL))); |
- |
// Updating the extensions page is a process that has back-and-forth |
// communication (i.e., backend tells extensions page something changed, |
// extensions page requests updated data, backend responds with updated data, |
@@ -616,7 +610,7 @@ IN_PROC_BROWSER_TEST_F(LazyBackgroundPageApiTest, UpdateExtensionsPage) { |
int num_tries = 0; |
while (!is_inactive && num_tries++ < kMaxTries) { |
EXPECT_TRUE(content::ExecuteScriptAndExtractBool( |
- frame, |
+ extensions_frame, |
"var ele = document.querySelectorAll('div.active-views');" |
"window.domAutomationController.send(" |
" ele[0].innerHTML.search('(Inactive)') > 0);", |