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

Unified Diff: content/public/test/render_view_test.cc

Issue 251903006: Attempt 2 to enable async data: URL loading. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix translation tests Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/content_tests.gypi ('k') | content/renderer/render_view_browsertest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/test/render_view_test.cc
diff --git a/content/public/test/render_view_test.cc b/content/public/test/render_view_test.cc
index 994c7be4ebc6a8fa14f2a82853ba1200d5c019d6..00404fd5bf4ef08d60478f108ed98d80597f3abe 100644
--- a/content/public/test/render_view_test.cc
+++ b/content/public/test/render_view_test.cc
@@ -20,6 +20,7 @@
#include "content/renderer/render_view_impl.h"
#include "content/renderer/renderer_main_platform_delegate.h"
#include "content/renderer/renderer_webkitplatformsupport_impl.h"
+#include "content/test/frame_load_waiter.h"
#include "content/test/mock_render_process.h"
#include "third_party/WebKit/public/platform/WebScreenInfo.h"
#include "third_party/WebKit/public/platform/WebURLRequest.h"
@@ -117,12 +118,10 @@ void RenderViewTest::LoadHTML(const char* html) {
std::string url_str = "data:text/html;charset=utf-8,";
url_str.append(html);
GURL url(url_str);
-
GetMainFrame()->loadRequest(WebURLRequest(url));
-
// The load actually happens asynchronously, so we pump messages to process
// the pending continuation.
- ProcessPendingMessages();
+ FrameLoadWaiter(view_->GetMainRenderFrame()).Wait();
}
void RenderViewTest::GoBack(const PageState& state) {
@@ -424,7 +423,7 @@ void RenderViewTest::GoToOffset(int offset, const PageState& state) {
// The load actually happens asynchronously, so we pump messages to process
// the pending continuation.
- ProcessPendingMessages();
+ FrameLoadWaiter(view_->GetMainRenderFrame()).Wait();
}
} // namespace content
« no previous file with comments | « content/content_tests.gypi ('k') | content/renderer/render_view_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698