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

Unified Diff: Source/web/tests/WebFrameTest.cpp

Issue 644573002: Disable async main thread HTML parsing (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: WebFrameTest should wait for background thread tasks Created 6 years, 2 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 | « Source/web/tests/FrameTestHelpers.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/tests/WebFrameTest.cpp
diff --git a/Source/web/tests/WebFrameTest.cpp b/Source/web/tests/WebFrameTest.cpp
index 7843934fc0f09ddb6ef58ca0c52987d5a8236ca1..5e337fad4aeb83254a18e9df2ec0b99d7e3a715b 100644
--- a/Source/web/tests/WebFrameTest.cpp
+++ b/Source/web/tests/WebFrameTest.cpp
@@ -4800,15 +4800,17 @@ TEST_F(WebFrameTest, MoveCaretSelectionTowardsWindowPointWithNoSelection)
TEST_F(WebFrameTest, NavigateToSandboxedMarkup)
{
+ FrameTestHelpers::TestWebFrameClient webFrameClient;
FrameTestHelpers::WebViewHelper webViewHelper;
- WebViewImpl* webViewImpl = webViewHelper.initializeAndLoad("about:blank", true);
+ WebViewImpl* webViewImpl = webViewHelper.initializeAndLoad("about:blank", true, &webFrameClient);
WebLocalFrameImpl* frame = toWebLocalFrameImpl(webViewHelper.webView()->mainFrame());
frame->document().setIsTransitionDocument();
std::string markup("<div id='foo'></div><script>document.getElementById('foo').setAttribute('dir', 'rtl')</script>");
frame->navigateToSandboxedMarkup(WebData(markup.data(), markup.length()));
- FrameTestHelpers::runPendingTasks();
+
+ webFrameClient.waitForLoadToComplete();
WebDocument document = webViewImpl->mainFrame()->document();
WebElement transitionElement = document.getElementById("foo");
« no previous file with comments | « Source/web/tests/FrameTestHelpers.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698