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

Unified Diff: chrome/browser/sync/api/sync_change.h

Issue 7978044: Sync/Valgrind: Add gmock printers for SyncChange, SyncData, SyncError. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: More. Created 9 years, 3 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 | chrome/browser/sync/api/sync_change.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/api/sync_change.h
diff --git a/chrome/browser/sync/api/sync_change.h b/chrome/browser/sync/api/sync_change.h
index f2bc40e05070dacd49d3ce8e6c8b9b35ddc1ebce..1b9787aabcc2157956390b5883aa93adc3b19817 100644
--- a/chrome/browser/sync/api/sync_change.h
+++ b/chrome/browser/sync/api/sync_change.h
@@ -6,6 +6,7 @@
#define CHROME_BROWSER_SYNC_API_SYNC_CHANGE_H_
#pragma once
+#include <iosfwd>
#include <string>
#include <vector>
@@ -48,6 +49,10 @@ class SyncChange {
// Returns a string representation of |change_type|.
static std::string ChangeTypeToString(SyncChangeType change_type);
+ // Returns a string representation of the entire object. Used for gmock
+ // printing method, PrintTo.
+ std::string ToString() const;
+
private:
SyncChangeType change_type_;
@@ -56,4 +61,7 @@ class SyncChange {
SyncData sync_data_;
};
+// gmock printer helper.
+void PrintTo(const SyncChange& sync_change, std::ostream* os);
+
#endif // CHROME_BROWSER_SYNC_API_SYNC_CHANGE_H_
« no previous file with comments | « no previous file | chrome/browser/sync/api/sync_change.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698