#include "components/reading_list/core/reading_list_model.h"
#include "base/location.h"
#include "base/memory/scoped_refptr.h"
#include "base/test/simple_test_clock.h"
#include "components/reading_list/core/fake_reading_list_model_storage.h"
#include "components/reading_list/core/mock_reading_list_model_observer.h"
#include "components/reading_list/core/reading_list_model_impl.h"
#include "components/sync/base/storage_type.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace {
_;
IsNull;
NotNull;
MATCHER_P(HasUrl, expected_url, "") { … }
base::Time AdvanceAndGetTime(base::SimpleTestClock* clock) { … }
std::vector<scoped_refptr<ReadingListEntry>> PopulateSampleEntries(
base::SimpleTestClock* clock) { … }
class ReadingListModelTest : public FakeReadingListModelStorage::Observer,
public testing::Test { … };
TEST_F(ReadingListModelTest, EmptyLoaded) { … }
TEST_F(ReadingListModelTest, ModelLoadSuccess) { … }
TEST_F(ReadingListModelTest, ModelLoadFailure) { … }
TEST_F(ReadingListModelTest, Shutdown) { … }
TEST_F(ReadingListModelTest, MarkEntrySeenIfExists) { … }
TEST_F(ReadingListModelTest, MarkAllSeen) { … }
TEST_F(ReadingListModelTest, DeleteAllEntries) { … }
TEST_F(ReadingListModelTest, GetAccountWhereEntryIsSavedToWhenSignedOut) { … }
TEST_F(ReadingListModelTest, GetAccountWhereEntryIsSavedToWhenSyncEnabled) { … }
TEST_F(ReadingListModelTest,
ReadingListModelCompletedBatchUpdatesShouldBeCalledUponSyncEnabled) { … }
TEST_F(ReadingListModelTest,
ReadingListModelCompletedBatchUpdatesShouldBeCalledUponSyncDisabled) { … }
TEST_F(ReadingListModelTest, AddEntry) { … }
TEST_F(ReadingListModelTest, AddExistingEntry) { … }
TEST_F(ReadingListModelTest, SyncAddEntry) { … }
TEST_F(ReadingListModelTest, SyncMergeEntry) { … }
TEST_F(ReadingListModelTest, RemoveEntryByUrlWhenUnread) { … }
TEST_F(ReadingListModelTest, RemoveEntryByUrlWhenRead) { … }
TEST_F(ReadingListModelTest, RemoveSyncEntryByUrlWhenUnread) { … }
TEST_F(ReadingListModelTest, RemoveSyncEntryByUrlWhenRead) { … }
TEST_F(ReadingListModelTest, ReadEntry) { … }
TEST_F(ReadingListModelTest, EntryFromURL) { … }
TEST_F(ReadingListModelTest, UnreadEntry) { … }
TEST_F(ReadingListModelTest, BatchUpdates) { … }
TEST_F(ReadingListModelTest, BatchUpdatesReentrant) { … }
TEST_F(ReadingListModelTest, UpdateEntryTitle) { … }
TEST_F(ReadingListModelTest, UpdateEntryDistilledState) { … }
TEST_F(ReadingListModelTest, UpdateDistilledInfo) { … }
TEST_F(ReadingListModelTest, UpdateReadEntryTitle) { … }
TEST_F(ReadingListModelTest, UpdateReadEntryState) { … }
TEST_F(ReadingListModelTest, UpdateReadDistilledInfo) { … }
TEST_F(ReadingListModelTest, TestTrimmingTitle) { … }
}