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

Unified Diff: content/browser/memory/memory_coordinator_impl_unittest.cc

Issue 2733323002: Changing multiprocess test SpawnChild to return a struct. (Closed)
Patch Set: Fix Windows build. Created 3 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
Index: content/browser/memory/memory_coordinator_impl_unittest.cc
diff --git a/content/browser/memory/memory_coordinator_impl_unittest.cc b/content/browser/memory/memory_coordinator_impl_unittest.cc
index 9158668f7419f992b420d049524e71d55e288a79..5209776abc518c534f33ec6fc60da2cce7e18b64 100644
--- a/content/browser/memory/memory_coordinator_impl_unittest.cc
+++ b/content/browser/memory/memory_coordinator_impl_unittest.cc
@@ -532,8 +532,12 @@ TEST_F(MemoryCoordinatorImplTest, MAYBE_GetStateForProcess) {
coordinator_->CreateChildMemoryCoordinator(1);
coordinator_->CreateChildMemoryCoordinator(2);
- base::Process process1 = SpawnChild("process1");
- base::Process process2 = SpawnChild("process2");
+
+ base::SpawnChildResult spawn_result = SpawnChild("process1");
+ base::Process process1 = std::move(spawn_result.process);
+ spawn_result = SpawnChild("process2");
dcheng 2017/03/14 05:28:51 Maybe make this a separate spawn_result so this ca
Jay Civelli 2017/03/14 16:29:12 Good idea, done.
+ base::Process process2 = std::move(spawn_result.process);
+
coordinator_->GetMockRenderProcessHost(1)->SetProcessHandle(
base::MakeUnique<base::ProcessHandle>(process1.Handle()));
coordinator_->GetMockRenderProcessHost(2)->SetProcessHandle(

Powered by Google App Engine
This is Rietveld 408576698