chromium/components/reading_list/core/reading_list_model_unittest.cc

// Copyright 2016 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#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 {};

// Tests creating an empty model.
TEST_F(ReadingListModelTest, EmptyLoaded) {}

// Tests successful load model.
TEST_F(ReadingListModelTest, ModelLoadSuccess) {}

// Tests errors during load model.
TEST_F(ReadingListModelTest, ModelLoadFailure) {}

// Tests the model's behavior during shutdown and destruction.
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) {}

// Tests adding entry.
TEST_F(ReadingListModelTest, AddEntry) {}

// Tests adding an entry that already exists.
TEST_F(ReadingListModelTest, AddExistingEntry) {}

// Tests addin entry from sync.
TEST_F(ReadingListModelTest, SyncAddEntry) {}

// Tests updating entry from sync.
TEST_F(ReadingListModelTest, SyncMergeEntry) {}

// Tests deleting entry when the read status is unread.
TEST_F(ReadingListModelTest, RemoveEntryByUrlWhenUnread) {}

// Tests deleting entry when the read status is read.
TEST_F(ReadingListModelTest, RemoveEntryByUrlWhenRead) {}

// Tests deleting entry from sync when the read status is unread.
TEST_F(ReadingListModelTest, RemoveSyncEntryByUrlWhenUnread) {}

// Tests deleting entry from sync when the read status is read.
TEST_F(ReadingListModelTest, RemoveSyncEntryByUrlWhenRead) {}

// Tests marking entry read.
TEST_F(ReadingListModelTest, ReadEntry) {}

// Tests accessing existing entry.
TEST_F(ReadingListModelTest, EntryFromURL) {}

// Tests mark entry unread.
TEST_F(ReadingListModelTest, UnreadEntry) {}

// Tests batch updates observers are called.
TEST_F(ReadingListModelTest, BatchUpdates) {}

// Tests batch updates are reentrant.
TEST_F(ReadingListModelTest, BatchUpdatesReentrant) {}

// Tests setting title on unread entry.
TEST_F(ReadingListModelTest, UpdateEntryTitle) {}

// Tests setting distillation state on unread entry.
TEST_F(ReadingListModelTest, UpdateEntryDistilledState) {}

// Tests setting distillation info on unread entry.
TEST_F(ReadingListModelTest, UpdateDistilledInfo) {}

// Tests setting title on read entry.
TEST_F(ReadingListModelTest, UpdateReadEntryTitle) {}

// Tests setting distillation state on read entry.
TEST_F(ReadingListModelTest, UpdateReadEntryState) {}

// Tests setting distillation info on read entry.
TEST_F(ReadingListModelTest, UpdateReadDistilledInfo) {}

// Tests that new line characters and spaces are collapsed in title.
TEST_F(ReadingListModelTest, TestTrimmingTitle) {}

}  // namespace