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

Side by Side Diff: content/renderer/render_view_browsertest.cc

Issue 2782063003: Remove redundant WebLocalFrame* parameter from runScriptsAtDocumentReady (Closed)
Patch Set: Created 3 years, 8 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
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 <stddef.h> 5 #include <stddef.h>
6 #include <stdint.h> 6 #include <stdint.h>
7 #include <tuple> 7 #include <tuple>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 1875 matching lines...) Expand 10 before | Expand all | Expand 10 after
1886 CommonNavigationParams common_params; 1886 CommonNavigationParams common_params;
1887 common_params.navigation_type = FrameMsg_Navigate_Type::DIFFERENT_DOCUMENT; 1887 common_params.navigation_type = FrameMsg_Navigate_Type::DIFFERENT_DOCUMENT;
1888 common_params.url = GURL("data:text/html,test data"); 1888 common_params.url = GURL("data:text/html,test data");
1889 TestRenderFrame* main_frame = static_cast<TestRenderFrame*>(frame()); 1889 TestRenderFrame* main_frame = static_cast<TestRenderFrame*>(frame());
1890 main_frame->Navigate(common_params, StartNavigationParams(), 1890 main_frame->Navigate(common_params, StartNavigationParams(),
1891 RequestNavigationParams()); 1891 RequestNavigationParams());
1892 1892
1893 // Emulate a 4xx/5xx main resource response with an empty body. 1893 // Emulate a 4xx/5xx main resource response with an empty body.
1894 main_frame->didReceiveResponse(response); 1894 main_frame->didReceiveResponse(response);
1895 main_frame->didFinishDocumentLoad(web_frame); 1895 main_frame->didFinishDocumentLoad(web_frame);
1896 main_frame->runScriptsAtDocumentReady(web_frame, true); 1896 main_frame->runScriptsAtDocumentReady(true);
1897 1897
1898 // The error page itself is loaded asynchronously. 1898 // The error page itself is loaded asynchronously.
1899 FrameLoadWaiter(main_frame).Wait(); 1899 FrameLoadWaiter(main_frame).Wait();
1900 const int kMaxOutputCharacters = 22; 1900 const int kMaxOutputCharacters = 22;
1901 EXPECT_EQ("A suffusion of yellow.", 1901 EXPECT_EQ("A suffusion of yellow.",
1902 WebFrameContentDumper::dumpWebViewAsText(view()->GetWebView(), 1902 WebFrameContentDumper::dumpWebViewAsText(view()->GetWebView(),
1903 kMaxOutputCharacters) 1903 kMaxOutputCharacters)
1904 .ascii()); 1904 .ascii());
1905 } 1905 }
1906 1906
(...skipping 686 matching lines...) Expand 10 before | Expand all | Expand 10 after
2593 ExpectPauseAndResume(3); 2593 ExpectPauseAndResume(3);
2594 blink::WebScriptSource source2( 2594 blink::WebScriptSource source2(
2595 WebString::fromUTF8("function func2() { func1(); }; func2();")); 2595 WebString::fromUTF8("function func2() { func1(); }; func2();"));
2596 frame()->GetWebFrame()->executeScriptInIsolatedWorld(17, &source2, 1); 2596 frame()->GetWebFrame()->executeScriptInIsolatedWorld(17, &source2, 1);
2597 2597
2598 EXPECT_FALSE(IsPaused()); 2598 EXPECT_FALSE(IsPaused());
2599 Detach(); 2599 Detach();
2600 } 2600 }
2601 2601
2602 } // namespace content 2602 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/render_frame_impl.cc ('k') | third_party/WebKit/Source/web/LocalFrameClientImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698