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

Unified Diff: third_party/WebKit/Source/web/tests/WebViewTest.cpp

Issue 1831423003: Audit test code callsites that need an explicit lifecycle update. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Clean up. Created 4 years, 9 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
Index: third_party/WebKit/Source/web/tests/WebViewTest.cpp
diff --git a/third_party/WebKit/Source/web/tests/WebViewTest.cpp b/third_party/WebKit/Source/web/tests/WebViewTest.cpp
index 4f742f91324baf7300f1645b1ab9a2012d740d21..f1286232661abb6efd1a508f7270724f251f73b4 100644
--- a/third_party/WebKit/Source/web/tests/WebViewTest.cpp
+++ b/third_party/WebKit/Source/web/tests/WebViewTest.cpp
@@ -2229,11 +2229,11 @@ TEST_F(WebViewTest, ChangeDisplayMode)
URLTestHelpers::registerMockedURLFromBaseURL(WebString::fromUTF8(m_baseURL.c_str()), WebString::fromUTF8("display_mode.html"));
WebView* webView = m_webViewHelper.initializeAndLoad(m_baseURL + "display_mode.html", true);
- std::string content = WebFrameContentDumper::dumpFrameTreeAsText(webView->mainFrame()->toWebLocalFrame(), 21).utf8();
+ std::string content = WebFrameContentDumper::dumpWebViewAsText(webView, 21).utf8();
EXPECT_EQ("regular-ui", content);
webView->setDisplayMode(WebDisplayModeMinimalUi);
- content = WebFrameContentDumper::dumpFrameTreeAsText(webView->mainFrame()->toWebLocalFrame(), 21).utf8();
+ content = WebFrameContentDumper::dumpWebViewAsText(webView, 21).utf8();
EXPECT_EQ("minimal-ui", content);
m_webViewHelper.reset();
}
@@ -2704,7 +2704,7 @@ TEST_F(WebViewTest, CompareSelectAllToContentAsText)
std::string actual = frame->selectionAsText().utf8();
const int kMaxOutputCharacters = 1024;
- std::string expected = WebFrameContentDumper::dumpFrameTreeAsText(frame, kMaxOutputCharacters).utf8();
+ std::string expected = WebFrameContentDumper::dumpWebViewAsText(webView, kMaxOutputCharacters).utf8();
EXPECT_EQ(expected, actual);
}
« no previous file with comments | « third_party/WebKit/Source/web/tests/WebFrameTest.cpp ('k') | third_party/WebKit/public/web/WebFrameContentDumper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698