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

Unified Diff: components/previews/core/previews_black_list_item.h

Issue 2448313002: Adding unit tests for PreviewsOptOutStoreSQL (Closed)
Patch Set: tbansal Created 4 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
« no previous file with comments | « components/previews/core/BUILD.gn ('k') | components/previews/core/previews_black_list_item.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/previews/core/previews_black_list_item.h
diff --git a/components/previews/core/previews_black_list_item.h b/components/previews/core/previews_black_list_item.h
index 462e61d1c4ade6782ada52f7035baef9dd35d5b2..03fa1b75c3a41bd1421803a4bca419c46f0fe123 100644
--- a/components/previews/core/previews_black_list_item.h
+++ b/components/previews/core/previews_black_list_item.h
@@ -37,20 +37,22 @@ class PreviewsBlackListItem {
void AddPreviewNavigation(bool opt_out, base::Time entry_time);
// Whether the host name corresponding to |this| should be disallowed from
// showing previews.
bool IsBlackListed(base::Time now) const;
base::Optional<base::Time> most_recent_opt_out_time() const {
return most_recent_opt_out_time_;
}
+ size_t OptOutRecordsSizeForTesting() const;
+
private:
// A previews navigation to this host is represented by time and whether the
// navigation was an opt out.
struct OptOutRecord {
OptOutRecord(base::Time entry_time, bool opt_out);
~OptOutRecord() {}
const base::Time
entry_time; // The time that the opt out state was determined.
const bool opt_out; // Whether the user opt out of the preview.
};
« no previous file with comments | « components/previews/core/BUILD.gn ('k') | components/previews/core/previews_black_list_item.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698