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

Unified Diff: chrome/browser/sync/test/integration/typed_urls_helper.cc

Issue 1087773002: Sync typed urls with typed_cont() == 0 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add unit test Created 5 years, 8 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
Index: chrome/browser/sync/test/integration/typed_urls_helper.cc
diff --git a/chrome/browser/sync/test/integration/typed_urls_helper.cc b/chrome/browser/sync/test/integration/typed_urls_helper.cc
index f3baf4196b288d44879fa3cc7860de35a78cb630..3df8d88580ca5bfb1df03fcb1f5fbe24f90b24d2 100644
--- a/chrome/browser/sync/test/integration/typed_urls_helper.cc
+++ b/chrome/browser/sync/test/integration/typed_urls_helper.cc
@@ -251,6 +251,16 @@ history::VisitVector GetVisitsFromClient(int index, history::URLID id) {
return GetVisitsFromHistoryService(service, id);
}
+history::VisitVector GetVisitsForURLFromClient(int index, const GURL& url) {
+ history::HistoryService* service =
+ HistoryServiceFactory::GetForProfileWithoutCreating(
+ test()->GetProfile(index));
+ history::URLRow url_row;
+ if (!GetUrlFromHistoryService(service, url, &url_row))
+ return history::VisitVector();
+ return GetVisitsFromHistoryService(service, url_row.id());
+}
+
void RemoveVisitsFromClient(int index, const history::VisitVector& visits) {
history::HistoryService* service =
HistoryServiceFactory::GetForProfileWithoutCreating(

Powered by Google App Engine
This is Rietveld 408576698