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

Unified Diff: chrome/test/live_sync/bookmark_model_verifier.h

Issue 5149001: Merge 65840 - Provide sync integration tests with a way to set a favicon for ... (Closed) Base URL: svn://svn.chromium.org/chrome/branches/552d/src/
Patch Set: Created 10 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: chrome/test/live_sync/bookmark_model_verifier.h
===================================================================
--- chrome/test/live_sync/bookmark_model_verifier.h (revision 66375)
+++ chrome/test/live_sync/bookmark_model_verifier.h (working copy)
@@ -7,6 +7,7 @@
#pragma once
#include <string>
+#include <vector>
#include "base/compiler_specific.h"
#include "chrome/browser/profile.h"
@@ -31,19 +32,11 @@
~BookmarkModelVerifier() {}
// Checks if the hierarchies in |model_a| and |model_b| are equivalent in
- // terms of the data model. Compares favicons if |compare_favicons| is true.
- // Returns true if they match.
+ // terms of the data model and favicon. Returns true if they both match.
// Note: Some peripheral fields like creation times are allowed to mismatch.
static bool ModelsMatch(BookmarkModel* model_a,
- BookmarkModel* model_b,
- bool compare_favicons) WARN_UNUSED_RESULT;
+ BookmarkModel* model_b) WARN_UNUSED_RESULT;
- // Same as the above method, but does not check if the favicons match.
- static bool ModelsMatch(BookmarkModel* model_a,
- BookmarkModel* model_b) WARN_UNUSED_RESULT {
- return ModelsMatch(model_a, model_b, false);
- }
-
// Checks if |model| contains any instances of two bookmarks with the same URL
// under the same parent folder. Returns true if even one instance is found.
static bool ContainsDuplicateBookmarks(BookmarkModel* model);
@@ -73,6 +66,13 @@
const BookmarkNode* node,
const string16& title);
+ // Sets the favicon of the same node in |model| and |verifier_model_| using
+ // the data in |icon_bytes_vector|.
+ // See BookmarkChangeProcessor::ApplyBookmarkFavicon for details.
+ void SetFavicon(BookmarkModel* model,
+ const BookmarkNode* node,
+ const std::vector<unsigned char>& icon_bytes_vector);
+
// Moves the same node to the same position in both |model| and
// |verifier_model_|. See BookmarkModel::Move for details.
void Move(BookmarkModel* model,
« no previous file with comments | « chrome/browser/sync/glue/bookmark_change_processor.cc ('k') | chrome/test/live_sync/bookmark_model_verifier.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698