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

Unified Diff: Source/core/page/PrintContextTest.cpp

Issue 1175563004: [SP] Save and restore slimming paint enabled state in SP-specific unit tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 6 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 | Source/core/paint/DisplayItemListPaintTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/page/PrintContextTest.cpp
diff --git a/Source/core/page/PrintContextTest.cpp b/Source/core/page/PrintContextTest.cpp
index c4e0e98ccefd25dcd041b7d33133284658bd7877..619a7fa696898bda9279a82276ed0ded57c814dd 100644
--- a/Source/core/page/PrintContextTest.cpp
+++ b/Source/core/page/PrintContextTest.cpp
@@ -190,6 +190,10 @@ void PrintContextTest::testBasicLinkTarget()
}
class PrintContextTestWithSlimmingPaint : public PrintContextTest {
+public:
+ PrintContextTestWithSlimmingPaint()
+ : m_originalSlimmingPaintEnabled(RuntimeEnabledFeatures::slimmingPaintEnabled()) { }
+
protected:
virtual void SetUp() override
{
@@ -198,9 +202,12 @@ protected:
}
virtual void TearDown() override
{
- RuntimeEnabledFeatures::setSlimmingPaintEnabled(false);
+ RuntimeEnabledFeatures::setSlimmingPaintEnabled(m_originalSlimmingPaintEnabled);
PrintContextTest::TearDown();
}
+
+private:
+ bool m_originalSlimmingPaintEnabled;
};
TEST_F(PrintContextTest, LinkTarget)
« no previous file with comments | « no previous file | Source/core/paint/DisplayItemListPaintTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698