public void Socket_ReceiveFromV4IPEndPointFromV4Client_Throws()
{
// "The supplied EndPoint of AddressFamily InterNetwork is not valid for this Socket, use InterNetworkV6 instead."
Socket socket = new Socket(SocketType.Dgram, ProtocolType.Udp);
socket.DualMode = false;
EndPoint receivedFrom = new IPEndPoint(IPAddress.Loopback, UnusedPort);
Assert.Throws<ArgumentException>(() =>
{
int received = socket.ReceiveFrom(new byte[1], ref receivedFrom);
});
}