chromium/chrome/browser/notifications/scheduler/internal/impression_store_unittest.cc

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

#include "chrome/browser/notifications/scheduler/internal/impression_store.h"

#include <map>
#include <memory>
#include <string>
#include <utility>

#include "base/memory/raw_ptr.h"
#include "base/test/task_environment.h"
#include "chrome/browser/notifications/proto/client_state.pb.h"
#include "chrome/browser/notifications/scheduler/internal/impression_types.h"
#include "chrome/browser/notifications/scheduler/internal/proto_conversion.h"
#include "components/leveldb_proto/public/proto_database.h"
#include "components/leveldb_proto/testing/fake_db.h"
#include "testing/gtest/include/gtest/gtest.h"

FakeDB;
InitStatus;
Entries;
DbEntries;
DbEntriesPtr;
TestClientStates;

namespace notifications {
namespace {

const char kClientStateKey[] =;
const ClientState kDefaultClientState;

// Test fixture to verify impression store.
class ImpressionStoreTest : public testing::Test {};

// Initializes an empty database should success.
TEST_F(ImpressionStoreTest, InitSuccessEmptyDb) {}

// Initialize non-empty database should success.
TEST_F(ImpressionStoreTest, InitSuccessWithData) {}

// Failure when loading the data will result in error.
TEST_F(ImpressionStoreTest, InitSuccessLoadFailed) {}

// Failed database initialization will result in error.
TEST_F(ImpressionStoreTest, InitFailed) {}

// Verifies adding data.
TEST_F(ImpressionStoreTest, Add) {}

// Verifies failure when adding data will result in error.
TEST_F(ImpressionStoreTest, AddFailed) {}

// Verifies updating data.
TEST_F(ImpressionStoreTest, Update) {}

// Verifies deleting data.
TEST_F(ImpressionStoreTest, Delete) {}

}  // namespace
}  // namespace notifications