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

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

Issue 1975753006: Pull to refresh: Use new reload type RELOAD_MAIN_RESOURCE (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review #14 and #16 Created 4 years, 7 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/WebFrameTest.cpp
diff --git a/third_party/WebKit/Source/web/tests/WebFrameTest.cpp b/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
index 7299c17c81981a4a03a1d4076a482fe5d40e93b7..83db4de40c8664cbd5c14f6bbf9d71efaa5c23c4 100644
--- a/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
+++ b/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
@@ -6064,20 +6064,20 @@ TEST_P(ParameterizedWebFrameTest, ReloadIframe)
class TestSameDocumentWebFrameClient : public FrameTestHelpers::TestWebFrameClient {
public:
TestSameDocumentWebFrameClient()
- : m_frameLoadTypeSameSeen(false)
+ : m_frameLoadTypeReloadMainResourceSeen(false)
{
}
virtual void willSendRequest(WebLocalFrame* frame, unsigned, WebURLRequest&, const WebURLResponse&)
{
- if (toWebLocalFrameImpl(frame)->frame()->loader().loadType() == FrameLoadTypeSame)
- m_frameLoadTypeSameSeen = true;
+ if (toWebLocalFrameImpl(frame)->frame()->loader().loadType() == FrameLoadTypeReloadMainResource)
+ m_frameLoadTypeReloadMainResourceSeen = true;
}
- bool frameLoadTypeSameSeen() const { return m_frameLoadTypeSameSeen; }
+ bool frameLoadTypeReloadMainResourceSeen() const { return m_frameLoadTypeReloadMainResourceSeen; }
private:
- bool m_frameLoadTypeSameSeen;
+ bool m_frameLoadTypeReloadMainResourceSeen;
};
TEST_P(ParameterizedWebFrameTest, NavigateToSame)
@@ -6086,13 +6086,13 @@ TEST_P(ParameterizedWebFrameTest, NavigateToSame)
TestSameDocumentWebFrameClient client;
FrameTestHelpers::WebViewHelper webViewHelper(this);
webViewHelper.initializeAndLoad(m_baseURL + "navigate_to_same.html", true, &client);
- EXPECT_FALSE(client.frameLoadTypeSameSeen());
+ EXPECT_FALSE(client.frameLoadTypeReloadMainResourceSeen());
FrameLoadRequest frameRequest(0, ResourceRequest(toLocalFrame(webViewHelper.webViewImpl()->page()->mainFrame())->document()->url()));
toLocalFrame(webViewHelper.webViewImpl()->page()->mainFrame())->loader().load(frameRequest);
FrameTestHelpers::pumpPendingRequestsForFrameToLoad(webViewHelper.webView()->mainFrame());
- EXPECT_TRUE(client.frameLoadTypeSameSeen());
+ EXPECT_TRUE(client.frameLoadTypeReloadMainResourceSeen());
}
class TestSameDocumentWithImageWebFrameClient : public FrameTestHelpers::TestWebFrameClient {
« no previous file with comments | « third_party/WebKit/Source/web/AssertMatchingEnums.cpp ('k') | third_party/WebKit/public/web/WebFrameLoadType.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698