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

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

Issue 2526163002: Rename blink::Page's load deferral to suspension (Closed)
Patch Set: Created 4 years, 1 month 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 ef005d58cdf8334cc271be77d064c5dcba90093d..54bd2a1092e198cf87d11417acd41d0bf32f5605 100644
--- a/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
+++ b/third_party/WebKit/Source/web/tests/WebFrameTest.cpp
@@ -74,7 +74,7 @@
#include "core/loader/FrameLoadRequest.h"
#include "core/loader/ThreadableLoader.h"
#include "core/page/Page.h"
-#include "core/page/ScopedPageLoadDeferrer.h"
+#include "core/page/ScopedPageSuspender.h"
#include "core/paint/PaintLayer.h"
#include "core/testing/NullExecutionContext.h"
#include "modules/mediastream/MediaStream.h"
@@ -9454,7 +9454,7 @@ TEST_P(ParameterizedWebFrameTest,
}
// See https://crbug.com/628942.
-TEST_P(ParameterizedWebFrameTest, DeferredPageLoadWithRemoteMainFrame) {
+TEST_P(ParameterizedWebFrameTest, SuspendedPageLoadWithRemoteMainFrame) {
// Prepare a page with a remote main frame.
FrameTestHelpers::TestWebViewClient viewClient;
FrameTestHelpers::TestWebRemoteFrameClient remoteClient;
@@ -9463,30 +9463,30 @@ TEST_P(ParameterizedWebFrameTest, DeferredPageLoadWithRemoteMainFrame) {
WebRemoteFrame* remoteRoot = view->mainFrame()->toWebRemoteFrame();
remoteRoot->setReplicatedOrigin(SecurityOrigin::createUnique());
- // Check that ScopedPageLoadDeferrer properly triggers deferred loading for
+ // Check that ScopedPageSuspender properly triggers deferred loading for
// the current Page.
Page* page = remoteRoot->toImplBase()->frame()->page();
- EXPECT_FALSE(page->defersLoading());
+ EXPECT_FALSE(page->suspended());
{
- ScopedPageLoadDeferrer deferrer;
- EXPECT_TRUE(page->defersLoading());
+ ScopedPageSuspender suspender;
+ EXPECT_TRUE(page->suspended());
}
- EXPECT_FALSE(page->defersLoading());
+ EXPECT_FALSE(page->suspended());
// Repeat this for a page with a local child frame, and ensure that the
- // child frame's loads are also deferred.
+ // child frame's loads are also suspended.
WebLocalFrame* webLocalChild = FrameTestHelpers::createLocalChild(remoteRoot);
registerMockedHttpURLLoad("foo.html");
FrameTestHelpers::loadFrame(webLocalChild, m_baseURL + "foo.html");
LocalFrame* localChild = toWebLocalFrameImpl(webLocalChild)->frame();
- EXPECT_FALSE(page->defersLoading());
+ EXPECT_FALSE(page->suspended());
EXPECT_FALSE(localChild->document()->fetcher()->defersLoading());
{
- ScopedPageLoadDeferrer deferrer;
- EXPECT_TRUE(page->defersLoading());
+ ScopedPageSuspender suspender;
+ EXPECT_TRUE(page->suspended());
EXPECT_TRUE(localChild->document()->fetcher()->defersLoading());
}
- EXPECT_FALSE(page->defersLoading());
+ EXPECT_FALSE(page->suspended());
EXPECT_FALSE(localChild->document()->fetcher()->defersLoading());
view->close();
« no previous file with comments | « third_party/WebKit/Source/web/tests/ChromeClientImplTest.cpp ('k') | third_party/WebKit/Source/web/tests/WebViewTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698