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

Unified Diff: Source/core/platform/animation/TimingFunctionTestHelper.h

Issue 39223002: TimingFunction test helper. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Using more permission regex for windows. Created 7 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: Source/core/platform/animation/TimingFunctionTestHelper.h
diff --git a/Source/core/testing/InternalProfilers.h b/Source/core/platform/animation/TimingFunctionTestHelper.h
similarity index 71%
copy from Source/core/testing/InternalProfilers.h
copy to Source/core/platform/animation/TimingFunctionTestHelper.h
index f948cffd6d152a097cb680017e8f85bb9c1a6e96..cf96685b566358f1fb4fc503340946be427f58d8 100644
--- a/Source/core/testing/InternalProfilers.h
+++ b/Source/core/platform/animation/TimingFunctionTestHelper.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2013 Google Inc. All rights reserved.
+ * Copyright (c) 2013, Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
@@ -28,26 +28,25 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef InternalProfilers_h
-#define InternalProfilers_h
-
-#include "wtf/Forward.h"
-#include "wtf/PassRefPtr.h"
-#include "wtf/RefCounted.h"
+/**
+ * Make testing with gtest and gmock nicer by adding pretty print and other
+ * helper functions.
+ */
-namespace WebCore {
+#ifndef TimingFunctionTestHelper_h
+#define TimingFunctionTestHelper_h
+#include "core/platform/animation/TimingFunction.h"
+#include <ostream> // NOLINT
-class InternalProfilers : public RefCounted<InternalProfilers> {
-public:
- static PassRefPtr<InternalProfilers> create() { return adoptRef(new InternalProfilers()); }
+namespace WebCore {
- void startHeapProfiling(const String& prefix);
- void stopHeapProfiling();
- void dumpHeapProfiling(const String& reason);
- String getHeapProfile();
-};
+void PrintTo(const LinearTimingFunction&, ::std::ostream*);
+void PrintTo(const CubicBezierTimingFunction&, ::std::ostream*);
+void PrintTo(const StepsTimingFunction&, ::std::ostream*);
+void PrintTo(const ChainedTimingFunction&, ::std::ostream*);
+void PrintTo(const TimingFunction&, ::std::ostream*);
} // namespace WebCore
« no previous file with comments | « Source/core/platform/animation/TimingFunction.h ('k') | Source/core/platform/animation/TimingFunctionTestHelper.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698