#include "chrome/browser/notifications/scheduler/test/test_utils.h"
#include <sstream>
#include <utility>
#include "base/containers/contains.h"
#include "base/logging.h"
#include "base/strings/stringprintf.h"
#include "chrome/browser/notifications/scheduler/internal/notification_entry.h"
#include "chrome/browser/notifications/scheduler/public/notification_data.h"
namespace notifications {
namespace test {
ImpressionTestData::ImpressionTestData(
SchedulerClientType type,
size_t current_max_daily_show,
std::vector<Impression> impressions,
std::optional<SuppressionInfo> suppression_info,
size_t negative_events_count,
std::optional<base::Time> last_negative_event_ts,
std::optional<base::Time> last_shown_ts)
: … { … }
ImpressionTestData::ImpressionTestData(const ImpressionTestData& other) =
default;
ImpressionTestData::~ImpressionTestData() = default;
void AddImpressionTestData(const ImpressionTestData& data,
ClientState* client_state) { … }
void AddImpressionTestData(
const std::vector<ImpressionTestData>& test_data_vec,
ImpressionHistoryTracker::ClientStates* client_states) { … }
void AddImpressionTestData(
const std::vector<ImpressionTestData>& test_data_vec,
std::vector<std::unique_ptr<ClientState>>* client_states) { … }
Impression CreateImpression(const base::Time& create_time,
UserFeedback feedback,
ImpressionResult impression_result,
bool integrated,
const std::string& guid,
SchedulerClientType type) { … }
std::string DebugString(const NotificationData* data) { … }
std::string DebugString(const NotificationEntry* entry) { … }
std::string DebugString(const ClientState* client_state) { … }
}
}