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

Unified Diff: ios/chrome/browser/reading_list/reading_list_model_unittest.cc

Issue 2491383002: Use Distilled path instead of DistilledURL. (Closed)
Patch Set: fix compilation 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
Index: ios/chrome/browser/reading_list/reading_list_model_unittest.cc
diff --git a/ios/chrome/browser/reading_list/reading_list_model_unittest.cc b/ios/chrome/browser/reading_list/reading_list_model_unittest.cc
index 1e97064edba99b6ff1e870c9ac20007c0a77526b..f1cfd4aa2be986865bc4a589727fbb7cf09d6cd1 100644
--- a/ios/chrome/browser/reading_list/reading_list_model_unittest.cc
+++ b/ios/chrome/browser/reading_list/reading_list_model_unittest.cc
@@ -272,15 +272,15 @@ TEST_F(ReadingListModelTest, UpdateEntryState) {
EXPECT_EQ(ReadingListEntry::PROCESSING, entry.DistilledState());
}
-TEST_F(ReadingListModelTest, UpdateDistilledURL) {
+TEST_F(ReadingListModelTest, UpdateDistilledPath) {
const GURL gurl("http://example.com");
const ReadingListEntry& entry = model_->AddEntry(gurl, "sample");
ClearCounts();
- model_->SetEntryDistilledURL(gurl, gurl);
+ model_->SetEntryDistilledPath(gurl, base::FilePath("distilled/page.html"));
AssertObserverCount(0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1);
EXPECT_EQ(ReadingListEntry::PROCESSED, entry.DistilledState());
- EXPECT_EQ(gurl, entry.DistilledURL());
+ EXPECT_EQ(base::FilePath("distilled/page.html"), entry.DistilledPath());
}
TEST_F(ReadingListModelTest, UpdateReadEntryTitle) {
@@ -307,17 +307,17 @@ TEST_F(ReadingListModelTest, UpdateReadEntryState) {
EXPECT_EQ(ReadingListEntry::PROCESSING, entry.DistilledState());
}
-TEST_F(ReadingListModelTest, UpdateReadDistilledURL) {
+TEST_F(ReadingListModelTest, UpdateReadDistilledPath) {
const GURL gurl("http://example.com");
model_->AddEntry(gurl, "sample");
model_->MarkReadByURL(gurl);
const ReadingListEntry& entry = model_->GetReadEntryAtIndex(0);
ClearCounts();
- model_->SetEntryDistilledURL(gurl, gurl);
+ model_->SetEntryDistilledPath(gurl, base::FilePath("distilled/page.html"));
AssertObserverCount(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1);
EXPECT_EQ(ReadingListEntry::PROCESSED, entry.DistilledState());
- EXPECT_EQ(gurl, entry.DistilledURL());
+ EXPECT_EQ(GURL("chrome://offline/distilled/page.html"), entry.DistilledURL());
}
// Tests that the callback is called when the entry is unread.

Powered by Google App Engine
This is Rietveld 408576698