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

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

Issue 23506013: Make the embedder responsible for creating the WebFrame (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fix lifetime on frame detach Created 7 years, 3 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') | Source/web/tests/ListenerLeakTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/tests/LinkHighlightTest.cpp
diff --git a/Source/web/tests/LinkHighlightTest.cpp b/Source/web/tests/LinkHighlightTest.cpp
index 92598146ece44141344f32523ba09d29b54af30c..40bc3e82f3294c008afd536acdb9accfd5e65200 100644
--- a/Source/web/tests/LinkHighlightTest.cpp
+++ b/Source/web/tests/LinkHighlightTest.cpp
@@ -60,7 +60,8 @@ TEST(LinkHighlightTest, verifyWebViewImplIntegration)
const std::string fileName("test_touch_link_highlight.html");
URLTestHelpers::registerMockedURLFromBaseURL(WebString::fromUTF8(baseURL.c_str()), WebString::fromUTF8("test_touch_link_highlight.html"));
- WebViewImpl* webViewImpl = toWebViewImpl(FrameTestHelpers::createWebViewAndLoad(baseURL + fileName, true));
+ FrameTestHelpers::WebViewHelper webViewHelper;
+ WebViewImpl* webViewImpl = webViewHelper.initializeAndLoad(baseURL + fileName, true);
int pageWidth = 640;
int pageHeight = 480;
webViewImpl->resize(WebSize(pageWidth, pageHeight));
@@ -122,7 +123,6 @@ TEST(LinkHighlightTest, verifyWebViewImplIntegration)
}
ASSERT_EQ(0U, webViewImpl->numLinkHighlights());
- webViewImpl->close();
Platform::current()->unitTestSupport()->unregisterAllMockedURLs();
}
@@ -165,7 +165,8 @@ TEST(LinkHighlightTest, resetDuringNodeRemoval)
const std::string fileName("test_touch_link_highlight.html");
URLTestHelpers::registerMockedURLFromBaseURL(WebString::fromUTF8(baseURL.c_str()), WebString::fromUTF8("test_touch_link_highlight.html"));
- WebViewImpl* webViewImpl = toWebViewImpl(FrameTestHelpers::createWebViewAndLoad(baseURL + fileName, true, 0, compositingWebViewClient()));
+ FrameTestHelpers::WebViewHelper webViewHelper;
+ WebViewImpl* webViewImpl = webViewHelper.initializeAndLoad(baseURL + fileName, true, 0, compositingWebViewClient());
int pageWidth = 640;
int pageHeight = 480;
@@ -192,7 +193,6 @@ TEST(LinkHighlightTest, resetDuringNodeRemoval)
webViewImpl->layout();
ASSERT_EQ(0U, highlightLayer->numLinkHighlights());
- webViewImpl->close();
Platform::current()->unitTestSupport()->unregisterAllMockedURLs();
}
@@ -202,7 +202,8 @@ TEST(LinkHighlightTest, multipleHighlights)
const std::string fileName("test_touch_link_highlight.html");
URLTestHelpers::registerMockedURLFromBaseURL(WebString::fromUTF8(baseURL.c_str()), WebString::fromUTF8("test_touch_link_highlight.html"));
- WebViewImpl* webViewImpl = toWebViewImpl(FrameTestHelpers::createWebViewAndLoad(baseURL + fileName, true, 0, compositingWebViewClient()));
+ FrameTestHelpers::WebViewHelper webViewHelper;
+ WebViewImpl* webViewImpl = webViewHelper.initializeAndLoad(baseURL + fileName, true, 0, compositingWebViewClient());
int pageWidth = 640;
int pageHeight = 480;
@@ -223,7 +224,6 @@ TEST(LinkHighlightTest, multipleHighlights)
webViewImpl->enableTapHighlights(highlightNodes);
EXPECT_EQ(2U, webViewImpl->numLinkHighlights());
- webViewImpl->close();
Platform::current()->unitTestSupport()->unregisterAllMockedURLs();
}
« no previous file with comments | « Source/web/tests/FrameTestHelpers.cpp ('k') | Source/web/tests/ListenerLeakTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698