Chromium Code Reviews| Index: components/reading_list/ios/reading_list_model_unittest.mm |
| diff --git a/components/reading_list/ios/reading_list_model_unittest.mm b/components/reading_list/ios/reading_list_model_unittest.mm |
| index 563c1c378736ba0c2f1af6fb861202b915c0f10c..c80d96c5c805f5d2160c2edc46fdf9089698f862 100644 |
| --- a/components/reading_list/ios/reading_list_model_unittest.mm |
| +++ b/components/reading_list/ios/reading_list_model_unittest.mm |
| @@ -375,8 +375,10 @@ TEST_F(ReadingListModelTest, SyncMergeEntry) { |
| SetStorage(std::move(storage)); |
| model_->AddEntry(GURL("http://example.com"), "sample", |
| reading_list::ADDED_VIA_CURRENT_APP); |
| - model_->SetEntryDistilledPath(GURL("http://example.com"), |
| - base::FilePath("distilled/page.html")); |
| + const base::FilePath distilled_path("distilled/page.html"); |
| + const GURL distilled_url("http://example.com/distilled"); |
| + model_->SetEntryDistilledInfo(GURL("http://example.com"), distilled_path, |
| + distilled_url); |
| const ReadingListEntry* local_entry = |
| model_->GetEntryByURL(GURL("http://example.com")); |
| int64_t local_update_time = local_entry->UpdateTime(); |
| @@ -605,7 +607,10 @@ TEST_F(ReadingListModelTest, UpdateDistilledPath) { |
| model_->AddEntry(gurl, "sample", reading_list::ADDED_VIA_CURRENT_APP); |
| ClearCounts(); |
| - model_->SetEntryDistilledPath(gurl, base::FilePath("distilled/page.html")); |
| + const base::FilePath distilled_path("distilled/page.html"); |
| + const GURL distilled_url("http://example.com/distilled"); |
| + model_->SetEntryDistilledInfo(GURL("http://example.com"), distilled_path, |
| + distilled_url); |
| AssertObserverCount(0, 0, 0, 0, 0, 0, 0, 1, 1); |
| EXPECT_EQ(ReadingListEntry::PROCESSED, entry.DistilledState()); |
| EXPECT_EQ(base::FilePath("distilled/page.html"), entry.DistilledPath()); |
|
gambard
2017/01/20 14:01:25
Add test for the distilled url.
Olivier
2017/01/20 14:43:51
Done.
|
| @@ -642,7 +647,10 @@ TEST_F(ReadingListModelTest, UpdateReadDistilledPath) { |
| const ReadingListEntry* entry = model_->GetEntryByURL(gurl); |
| ClearCounts(); |
| - model_->SetEntryDistilledPath(gurl, base::FilePath("distilled/page.html")); |
| + const base::FilePath distilled_path("distilled/page.html"); |
| + const GURL distilled_url("http://example.com/distilled"); |
| + model_->SetEntryDistilledInfo(GURL("http://example.com"), distilled_path, |
| + distilled_url); |
| AssertObserverCount(0, 0, 0, 0, 0, 0, 0, 1, 1); |
| EXPECT_EQ(ReadingListEntry::PROCESSED, entry->DistilledState()); |
| EXPECT_EQ(base::FilePath("distilled/page.html"), entry->DistilledPath()); |
|
gambard
2017/01/20 14:01:24
Add test for distilled url.
Olivier
2017/01/20 14:43:51
Done.
|