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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutTestHelper.cpp

Issue 2278723002: Evict resources from memory cache after running rendering test. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Evict resources after running RenderingTest. Created 4 years, 4 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/layout/LayoutTestHelper.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutTestHelper.cpp b/third_party/WebKit/Source/core/layout/LayoutTestHelper.cpp
index d1b4ac06bed47059c890b3262ed186eda852e980..5c4c3788b69292842322c4594442b0215a97b7d3 100644
--- a/third_party/WebKit/Source/core/layout/LayoutTestHelper.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutTestHelper.cpp
@@ -4,6 +4,7 @@
#include "core/layout/LayoutTestHelper.h"
+#include "core/fetch/MemoryCache.h"
#include "core/frame/FrameHost.h"
#include "core/html/HTMLIFrameElement.h"
#include "platform/scroll/ScrollbarTheme.h"
@@ -42,6 +43,9 @@ void RenderingTest::TearDown()
// RuntimeEnabledFeatures setting during teardown, which happens before our destructor
// getting invoked, breaking the assumption that REF can't change during Blink lifetime.
m_pageHolder = nullptr;
+
+ // Clear memory cache, otherwise we can leak pruned resources.
+ memoryCache()->evictResources();
haraken 2016/08/26 00:58:49 Just help me understand: What's a difference betwe
}
Document& RenderingTest::setupChildIframe(const AtomicString& iframeElementId, const String& htmlContentOfIframe)
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698