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

Unified Diff: chrome/browser/renderer_host/render_process_host_chrome_browsertest.cc

Issue 1763353002: Disable UpdateProcessPriority() on startup by default. (Closed) Base URL: https://luckyluke-private.googlesource.com/src@a_3_thread_handles
Patch Set: fix test Created 4 years, 9 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | content/browser/renderer_host/render_process_host_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/renderer_host/render_process_host_chrome_browsertest.cc
diff --git a/chrome/browser/renderer_host/render_process_host_chrome_browsertest.cc b/chrome/browser/renderer_host/render_process_host_chrome_browsertest.cc
index 97ea95845b13123c911d0b259e0f15de69ceee16..fa089eee5d75c78a2fb1c5fea1bd58e8335e0e6f 100644
--- a/chrome/browser/renderer_host/render_process_host_chrome_browsertest.cc
+++ b/chrome/browser/renderer_host/render_process_host_chrome_browsertest.cc
@@ -336,13 +336,26 @@ IN_PROC_BROWSER_TEST_F(ChromeRenderProcessHostTest, Backgrounding) {
EXPECT_NE(process3.Pid(), process2.Pid());
EXPECT_TRUE(process1.IsProcessBackgrounded());
EXPECT_FALSE(process2.IsProcessBackgrounded());
- EXPECT_TRUE(process3.IsProcessBackgrounded());
+ // TODO(gab): The new background tab should be backgrounded but it currently
+ // intentionally isn't per a workaround to https://crbug.com/560446 in
+ // RenderProcessHostImpl::OnProcessLaunched().
+ EXPECT_FALSE(process3.IsProcessBackgrounded());
// Navigate back to the first page. Its renderer should be in foreground
// again while the other renderers should be backgrounded.
EXPECT_EQ(process1.Pid(), ShowSingletonTab(page1).Pid());
EXPECT_FALSE(process1.IsProcessBackgrounded());
EXPECT_TRUE(process2.IsProcessBackgrounded());
+ // TODO(gab): Same as above.
+ EXPECT_FALSE(process3.IsProcessBackgrounded());
+
+ // TODO(gab): Remove this when https://crbug.com/560446 is fixed, but for now
+ // confirm that the correct state is at least achieved when tab #3 is
+ // explicitly foregrounded and re-backgrounded.
+ EXPECT_EQ(process3.Pid(), ShowSingletonTab(page3).Pid());
+ EXPECT_EQ(process1.Pid(), ShowSingletonTab(page1).Pid());
+ EXPECT_FALSE(process1.IsProcessBackgrounded());
+ EXPECT_TRUE(process2.IsProcessBackgrounded());
EXPECT_TRUE(process3.IsProcessBackgrounded());
}
#endif
« no previous file with comments | « no previous file | content/browser/renderer_host/render_process_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698