public static async Task SendPings_ReuseInstance_Hostname()
{
IPAddress localIpAddress = await TestSettings.GetLocalIPAddress();
using (Ping p = new Ping())
{
for (int i = 0; i < 3; i++)
{
PingReply pingReply = await p.SendPingAsync(TestSettings.LocalHost);
Assert.Equal(IPStatus.Success, pingReply.Status);
Assert.True(pingReply.Address.Equals(localIpAddress));
}
}
}