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

Unified Diff: chrome/browser/history/in_memory_url_index_unittest.cc

Issue 352913002: Port HistoryService::ScheduleDBTask to CancelableTaskTracker (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix lifetime of base::CancelableTaskTracker for HistoryModelWorker Created 6 years, 6 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 | « chrome/browser/history/in_memory_url_index.cc ('k') | chrome/browser/history/top_sites_impl_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/history/in_memory_url_index_unittest.cc
diff --git a/chrome/browser/history/in_memory_url_index_unittest.cc b/chrome/browser/history/in_memory_url_index_unittest.cc
index 7f5020e2f2bfb1d7f1cfc07feaa97ca61106ae2a..ee1bd92ce508e162293a77bb25d4754875791ea8 100644
--- a/chrome/browser/history/in_memory_url_index_unittest.cc
+++ b/chrome/browser/history/in_memory_url_index_unittest.cc
@@ -103,6 +103,7 @@ class InMemoryURLIndexTest : public testing::Test {
// Pass-through functions to simplify our friendship with InMemoryURLIndex.
URLIndexPrivateData* GetPrivateData() const;
+ base::CancelableTaskTracker* GetPrivateDataTracker() const;
void ClearPrivateData();
void set_history_dir(const base::FilePath& dir_path);
bool GetCacheFilePath(base::FilePath* file_path) const;
@@ -148,6 +149,12 @@ URLIndexPrivateData* InMemoryURLIndexTest::GetPrivateData() const {
return url_index_->private_data();
}
+base::CancelableTaskTracker* InMemoryURLIndexTest::GetPrivateDataTracker()
+ const {
+ DCHECK(url_index_->private_data_tracker());
+ return url_index_->private_data_tracker();
+}
+
void InMemoryURLIndexTest::ClearPrivateData() {
return url_index_->ClearPrivateData();
}
@@ -181,9 +188,11 @@ const std::set<std::string>& InMemoryURLIndexTest::scheme_whitelist() {
}
bool InMemoryURLIndexTest::UpdateURL(const URLRow& row) {
- return GetPrivateData()->UpdateURL(
- history_service_, row, url_index_->languages_,
- url_index_->scheme_whitelist_);
+ return GetPrivateData()->UpdateURL(history_service_,
+ row,
+ url_index_->languages_,
+ url_index_->scheme_whitelist_,
+ GetPrivateDataTracker());
}
bool InMemoryURLIndexTest::DeleteURL(const GURL& url) {
« no previous file with comments | « chrome/browser/history/in_memory_url_index.cc ('k') | chrome/browser/history/top_sites_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698