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

Unified Diff: third_party/WebKit/Source/core/loader/FrameFetchContextTest.cpp

Issue 1418003006: Simplify starting a navigation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: enum-ify Created 5 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/core/loader/FrameFetchContextTest.cpp
diff --git a/third_party/WebKit/Source/core/loader/FrameFetchContextTest.cpp b/third_party/WebKit/Source/core/loader/FrameFetchContextTest.cpp
index 9e12e0e2984f020b042b14d40f9c484010da9254..bc5e3c2bbeaf489e66366c95cf1dcc0a3b79e5d3 100644
--- a/third_party/WebKit/Source/core/loader/FrameFetchContextTest.cpp
+++ b/third_party/WebKit/Source/core/loader/FrameFetchContextTest.cpp
@@ -96,8 +96,8 @@ protected:
{
dummyPageHolder = DummyPageHolder::create(IntSize(500, 500));
dummyPageHolder->page().setDeviceScaleFactor(1.0);
- documentLoader = DocumentLoader::create(&dummyPageHolder->frame(), ResourceRequest("http://www.example.com"), SubstituteData());
document = toHTMLDocument(&dummyPageHolder->document());
+ documentLoader = document->loader();
fetchContext = static_cast<FrameFetchContext*>(&documentLoader->fetcher()->context());
owner = StubFrameOwner::create();
FrameFetchContext::provideDocumentToContext(*fetchContext, document.get());
@@ -105,11 +105,9 @@ protected:
void TearDown() override
{
- documentLoader->detachFromFrame();
documentLoader.clear();
if (childFrame) {
- childDocumentLoader->detachFromFrame();
childDocumentLoader.clear();
childFrame->detach(FrameDetachType::Remove);
}
@@ -121,8 +119,8 @@ protected:
childFrame = LocalFrame::create(childClient.get(), document->frame()->host(), owner.get());
childFrame->setView(FrameView::create(childFrame.get(), IntSize(500, 500)));
childFrame->init();
- childDocumentLoader = DocumentLoader::create(childFrame.get(), ResourceRequest("http://www.example.com"), SubstituteData());
childDocument = childFrame->document();
+ childDocumentLoader = childDocument->loader();
FrameFetchContext* childFetchContext = static_cast<FrameFetchContext*>(&childDocumentLoader->fetcher()->context());
FrameFetchContext::provideDocumentToContext(*childFetchContext, childDocument.get());
return childFetchContext;
« no previous file with comments | « third_party/WebKit/Source/core/loader/FrameFetchContext.cpp ('k') | third_party/WebKit/Source/core/loader/FrameLoader.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698