#include "third_party/blink/renderer/platform/p2p/ipc_network_manager.h"
#include <memory>
#include "base/ranges/algorithm.h"
#include "net/base/ip_address.h"
#include "net/base/network_change_notifier.h"
#include "net/base/network_interfaces.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/blink/renderer/platform/heap/garbage_collected.h"
#include "third_party/blink/renderer/platform/p2p/network_list_manager.h"
#include "third_party/webrtc/rtc_base/mdns_responder_interface.h"
namespace blink {
namespace {
class MockP2PSocketDispatcher
: public GarbageCollected<MockP2PSocketDispatcher>,
public NetworkListManager { … };
class EmptyMdnsResponder : public webrtc::MdnsResponderInterface { … };
}
static const char kIPv6PublicAddrString1[] = …;
static const char kIPv6PublicAddrString2[] = …;
static const char kIPv4MappedAddrString[] = …;
class IpcNetworkManagerTest : public testing::Test { … };
TEST_F(IpcNetworkManagerTest, TestMergeNetworkList) { … }
TEST_F(IpcNetworkManagerTest, DeterminesNetworkTypeFromNameIfUnknown) { … }
TEST_F(IpcNetworkManagerTest, DeterminesVPNFromMacAddress) { … }
TEST_F(IpcNetworkManagerTest, DeterminesNotVPN) { … }
TEST_F(IpcNetworkManagerTest,
ServeAsMdnsResponderProviderForNetworksEnumerated) { … }
}