#include "net/log/test_net_log_util.h"
#include <cstddef>
#include "net/log/net_log_entry.h"
namespace net {
namespace {
size_t GetIndex(const std::vector<NetLogEntry>& entries, int offset) { … }
}
::testing::AssertionResult LogContainsEvent(
const std::vector<NetLogEntry>& entries,
int offset,
NetLogEventType expected_event,
NetLogEventPhase expected_phase) { … }
::testing::AssertionResult LogContainsBeginEvent(
const std::vector<NetLogEntry>& entries,
int offset,
NetLogEventType expected_event) { … }
::testing::AssertionResult LogContainsEndEvent(
const std::vector<NetLogEntry>& entries,
int offset,
NetLogEventType expected_event) { … }
::testing::AssertionResult LogContainsEntryWithType(
const std::vector<NetLogEntry>& entries,
int offset,
NetLogEventType type) { … }
::testing::AssertionResult LogContainsEntryWithTypeAfter(
const std::vector<NetLogEntry>& entries,
int start_offset,
NetLogEventType type) { … }
size_t ExpectLogContainsSomewhere(const std::vector<NetLogEntry>& entries,
size_t min_offset,
NetLogEventType expected_event,
NetLogEventPhase expected_phase) { … }
size_t ExpectLogContainsSomewhereAfter(const std::vector<NetLogEntry>& entries,
size_t start_offset,
NetLogEventType expected_event,
NetLogEventPhase expected_phase) { … }
std::optional<std::string> GetOptionalStringValueFromParams(
const NetLogEntry& entry,
std::string_view path) { … }
std::optional<bool> GetOptionalBooleanValueFromParams(const NetLogEntry& entry,
std::string_view path) { … }
std::optional<int> GetOptionalIntegerValueFromParams(const NetLogEntry& entry,
std::string_view path) { … }
std::optional<int> GetOptionalNetErrorCodeFromParams(const NetLogEntry& entry) { … }
std::string GetStringValueFromParams(const NetLogEntry& entry,
std::string_view path) { … }
int GetIntegerValueFromParams(const NetLogEntry& entry, std::string_view path) { … }
bool GetBooleanValueFromParams(const NetLogEntry& entry,
std::string_view path) { … }
int GetNetErrorCodeFromParams(const NetLogEntry& entry) { … }
}