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

Side by Side Diff: content/public/test/render_view_test.cc

Issue 1715203002: Stop async spellchecker before running the leak detector. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase + parameterize WebLeakDetector over WebFrames instead Created 4 years, 10 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 unified diff | Download patch
« no previous file with comments | « no previous file | content/shell/renderer/layout_test/blink_test_runner.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) 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 "content/public/test/render_view_test.h" 5 #include "content/public/test/render_view_test.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <cctype> 9 #include <cctype>
10 10
(...skipping 371 matching lines...) Expand 10 before | Expand all | Expand 10 after
382 382
383 void RenderViewTest::TearDown() { 383 void RenderViewTest::TearDown() {
384 // Run the loop so the release task from the renderwidget executes. 384 // Run the loop so the release task from the renderwidget executes.
385 ProcessPendingMessages(); 385 ProcessPendingMessages();
386 386
387 render_thread_->SendCloseMessage(); 387 render_thread_->SendCloseMessage();
388 388
389 scoped_ptr<blink::WebLeakDetector> leak_detector = 389 scoped_ptr<blink::WebLeakDetector> leak_detector =
390 make_scoped_ptr(blink::WebLeakDetector::create(this)); 390 make_scoped_ptr(blink::WebLeakDetector::create(this));
391 391
392 leak_detector->prepareForLeakDetection(); 392 leak_detector->prepareForLeakDetection(view_->GetWebView()->mainFrame());
393 393
394 view_ = NULL; 394 view_ = NULL;
395 mock_process_.reset(); 395 mock_process_.reset();
396 396
397 // After telling the view to close and resetting mock_process_ we may get 397 // After telling the view to close and resetting mock_process_ we may get
398 // some new tasks which need to be processed before shutting down WebKit 398 // some new tasks which need to be processed before shutting down WebKit
399 // (http://crbug.com/21508). 399 // (http://crbug.com/21508).
400 base::RunLoop().RunUntilIdle(); 400 base::RunLoop().RunUntilIdle();
401 401
402 #if defined(OS_MACOSX) 402 #if defined(OS_MACOSX)
(...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after
722 TestRenderFrame* frame = 722 TestRenderFrame* frame =
723 static_cast<TestRenderFrame*>(impl->GetMainRenderFrame()); 723 static_cast<TestRenderFrame*>(impl->GetMainRenderFrame());
724 frame->Navigate(common_params, StartNavigationParams(), request_params); 724 frame->Navigate(common_params, StartNavigationParams(), request_params);
725 725
726 // The load actually happens asynchronously, so we pump messages to process 726 // The load actually happens asynchronously, so we pump messages to process
727 // the pending continuation. 727 // the pending continuation.
728 FrameLoadWaiter(frame).Wait(); 728 FrameLoadWaiter(frame).Wait();
729 } 729 }
730 730
731 } // namespace content 731 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/shell/renderer/layout_test/blink_test_runner.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698