#include "discovery/public/dns_sd_service_watcher.h"
#include <algorithm>
#include "gmock/gmock.h"
#include "gtest/gtest.h"
#include "util/std_util.h"
_;
ContainerEq;
IsSubsetOf;
IsSupersetOf;
StrictMock;
namespace openscreen::discovery {
namespace {
std::vector<std::string> ConvertRefs(
const std::vector<std::reference_wrapper<const std::string>>& value) { … }
static const IPAddress kAddressV4(192, 168, 0, 0);
static const IPEndpoint kEndpointV4{ … };
constexpr char kCastServiceId[] = …;
constexpr char kCastDomainId[] = …;
constexpr NetworkInterfaceIndex kNetworkInterface = …;
class MockDnsSdService : public DnsSdService { … };
}
class TestServiceWatcher : public DnsSdServiceWatcher<std::string> { … };
class DnsSdServiceWatcherTests : public testing::Test { … };
TEST_F(DnsSdServiceWatcherTests, StartStopDiscoveryWorks) { … }
TEST(DnsSdServiceWatcherTest, RefreshFailsBeforeDiscoveryStarts) { … }
TEST_F(DnsSdServiceWatcherTests, RefreshDiscoveryWorks) { … }
TEST_F(DnsSdServiceWatcherTests, CreatingUpdatingDeletingInstancesWork) { … }
}