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

Unified Diff: cc/output/filter_operations_unittest.cc

Issue 2574713003: Add toString() for paint property node classes (Closed)
Patch Set: Update test Created 4 years 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 | « cc/output/filter_operations.cc ('k') | third_party/WebKit/Source/core/paint/PaintPropertyTreePrinter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/output/filter_operations_unittest.cc
diff --git a/cc/output/filter_operations_unittest.cc b/cc/output/filter_operations_unittest.cc
index 89ed4608d4ffe47c88037d2bb1ad4dfc167e650e..8a32e663d5447e6c6ec09462d3448927b4cfb0b6 100644
--- a/cc/output/filter_operations_unittest.cc
+++ b/cc/output/filter_operations_unittest.cc
@@ -956,5 +956,16 @@ TEST(FilterOperationsTest, BlendRaggedSequences) {
EXPECT_EQ(to, blended);
}
+TEST(FilterOperationsTest, ToString) {
+ FilterOperations filters;
+ EXPECT_EQ(std::string("{\"FilterOperations\":[]}"), filters.ToString());
+
+ filters.Append(FilterOperation::CreateSaturateFilter(3.f));
+ filters.Append(FilterOperation::CreateBlurFilter(2.f));
+ EXPECT_EQ(std::string("{\"FilterOperations\":[{\"amount\":3.0,\"type\":2},"
+ "{\"amount\":2.0,\"type\":8}]}"),
+ filters.ToString());
+}
+
} // namespace
} // namespace cc
« no previous file with comments | « cc/output/filter_operations.cc ('k') | third_party/WebKit/Source/core/paint/PaintPropertyTreePrinter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698