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

Unified Diff: cc/test/output_test_common.cc

Issue 273823002: Adding gtest helpers for BeginFrameArgs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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
« cc/test/output_test_common.h ('K') | « cc/test/output_test_common.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/output_test_common.cc
diff --git a/cc/test/output_test_common.cc b/cc/test/output_test_common.cc
index 6995796e5e0ff6f98ecc3c46578e9a5197e8c71b..2743755306f2d44e74cf4cf694a17d680889dd37 100644
--- a/cc/test/output_test_common.cc
+++ b/cc/test/output_test_common.cc
@@ -32,4 +32,15 @@ BeginFrameArgs BeginFrameArgsCreateQuick(int64 frame_time,
base::TimeDelta::FromInternalValue(deadline));
}
+bool operator==(BeginFrameArgs lhs, BeginFrameArgs rhs) {
+ return (lhs.frame_time == rhs.frame_time) && (lhs.deadline == rhs.deadline) &&
+ (lhs.interval == rhs.interval);
+}
+
+void PrintTo(const BeginFrameArgs& args, ::std::ostream* os) {
+ *os << "BeginFrameArgs(" << args.frame_time.ToInternalValue() << ", "
+ << args.deadline.ToInternalValue() << ", "
+ << args.interval.InMicroseconds() << "us)";
+}
+
} // namespace cc
« cc/test/output_test_common.h ('K') | « cc/test/output_test_common.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698