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

Side by Side Diff: chrome/browser/debugger/devtools_sanity_unittest.cc

Issue 8399007: Removing dedicated worker-related IPC codei (first round). (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: CR feedback Created 9 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/ui/webui/workers_ui.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/bind.h" 5 #include "base/bind.h"
6 #include "base/command_line.h" 6 #include "base/command_line.h"
7 #include "base/memory/ref_counted.h" 7 #include "base/memory/ref_counted.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "base/stringprintf.h" 9 #include "base/stringprintf.h"
10 #include "base/test/test_timeouts.h" 10 #include "base/test/test_timeouts.h"
(...skipping 359 matching lines...) Expand 10 before | Expand all | Expand 10 after
370 } 370 }
371 371
372 static void WaitForFirstSharedWorkerOnIOThread( 372 static void WaitForFirstSharedWorkerOnIOThread(
373 scoped_refptr<WorkerData> worker_data) { 373 scoped_refptr<WorkerData> worker_data) {
374 BrowserChildProcessHost::Iterator iter(ChildProcessInfo::WORKER_PROCESS); 374 BrowserChildProcessHost::Iterator iter(ChildProcessInfo::WORKER_PROCESS);
375 for (; !iter.Done(); ++iter) { 375 for (; !iter.Done(); ++iter) {
376 WorkerProcessHost* worker = static_cast<WorkerProcessHost*>(*iter); 376 WorkerProcessHost* worker = static_cast<WorkerProcessHost*>(*iter);
377 const WorkerProcessHost::Instances& instances = worker->instances(); 377 const WorkerProcessHost::Instances& instances = worker->instances();
378 for (WorkerProcessHost::Instances::const_iterator i = instances.begin(); 378 for (WorkerProcessHost::Instances::const_iterator i = instances.begin();
379 i != instances.end(); ++i) { 379 i != instances.end(); ++i) {
380 if (!i->shared()) 380
381 continue;
382 worker_data->worker_process_id = worker->id(); 381 worker_data->worker_process_id = worker->id();
383 worker_data->worker_route_id = i->worker_route_id(); 382 worker_data->worker_route_id = i->worker_route_id();
384 BrowserThread::PostTask(BrowserThread::UI, FROM_HERE, 383 BrowserThread::PostTask(BrowserThread::UI, FROM_HERE,
385 new MessageLoop::QuitTask); 384 new MessageLoop::QuitTask);
386 return; 385 return;
387 } 386 }
388 } 387 }
389 388
390 WorkerService::GetInstance()->AddObserver( 389 WorkerService::GetInstance()->AddObserver(
391 new WorkerCreationObserver(worker_data.get())); 390 new WorkerCreationObserver(worker_data.get()));
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
547 546
548 // Reload page to restart the worker. 547 // Reload page to restart the worker.
549 ui_test_utils::NavigateToURL(browser(), url); 548 ui_test_utils::NavigateToURL(browser(), url);
550 549
551 // Wait until worker script is paused on the debugger statement. 550 // Wait until worker script is paused on the debugger statement.
552 RunTestFuntion(window_, "testPauseInSharedWorkerInitialization"); 551 RunTestFuntion(window_, "testPauseInSharedWorkerInitialization");
553 CloseDevToolsWindow(); 552 CloseDevToolsWindow();
554 } 553 }
555 554
556 } // namespace 555 } // namespace
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/webui/workers_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698