| Index: content/test/test_render_frame_host.cc
|
| diff --git a/content/test/test_render_frame_host.cc b/content/test/test_render_frame_host.cc
|
| index 6558a129032199dc9ab0101ae138eb3b566d3fea..6ae61c7aa62963d61d74907eb94122c02cd824ad 100644
|
| --- a/content/test/test_render_frame_host.cc
|
| +++ b/content/test/test_render_frame_host.cc
|
| @@ -34,6 +34,15 @@
|
|
|
| namespace content {
|
|
|
| +namespace {
|
| +
|
| +void CallbackRunner(const base::Closure& closure,
|
| + NavigationThrottle::ThrottleCheckResult result) {
|
| + closure.Run();
|
| +}
|
| +
|
| +} // namesapce
|
| +
|
| TestRenderFrameHostCreationObserver::TestRenderFrameHostCreationObserver(
|
| WebContents* web_contents)
|
| : WebContentsObserver(web_contents), last_created_frame_(NULL) {
|
| @@ -122,8 +131,8 @@ void TestRenderFrameHost::SimulateRedirect(const GURL& new_url) {
|
| NavigationRequest* request = frame_tree_node_->navigation_request();
|
| if (!request->loader_for_testing()) {
|
| base::RunLoop loop;
|
| - request->set_on_start_checks_complete_closure_for_testing(
|
| - loop.QuitClosure());
|
| + request->set_on_checks_complete_callback_for_testing(
|
| + base::Bind(&CallbackRunner, loop.QuitClosure()));
|
| loop.Run();
|
| }
|
| TestNavigationURLLoader* url_loader =
|
| @@ -194,8 +203,8 @@ void TestRenderFrameHost::SimulateNavigationError(const GURL& url,
|
| }
|
| if (!request->loader_for_testing()) {
|
| base::RunLoop loop;
|
| - request->set_on_start_checks_complete_closure_for_testing(
|
| - loop.QuitClosure());
|
| + request->set_on_checks_complete_callback_for_testing(
|
| + base::Bind(&CallbackRunner, loop.QuitClosure()));
|
| loop.Run();
|
| }
|
| TestNavigationURLLoader* url_loader =
|
| @@ -478,8 +487,8 @@ void TestRenderFrameHost::PrepareForCommitWithServerRedirect(
|
|
|
| if (!request->loader_for_testing()) {
|
| base::RunLoop loop;
|
| - request->set_on_start_checks_complete_closure_for_testing(
|
| - loop.QuitClosure());
|
| + request->set_on_checks_complete_callback_for_testing(
|
| + base::Bind(&CallbackRunner, loop.QuitClosure()));
|
| loop.Run();
|
| }
|
|
|
|
|