DoMsgRoundTrip() 공개 정적인 메소드

Send a message through the TCP channel, and expect it to return unchanged
Useful for testing I/O levels 1 and 2. This method must be called between Setup() and TearDown().
public static DoMsgRoundTrip ( string msg_send, string msg_expect ) : void
msg_send string
msg_expect string
리턴 void
예제 #1
0
        static public void TestMessageRoundTripIPv4()
        {
            var msg1 = "Sally sells seashells by the seashore.";

            TcpCommon.DoMsgRoundTrip(msg1 + "\n", msg1);
            TcpCommon.DoMsgRoundTrip(msg1 + "\r\n", msg1);

            var msg2a = "The seashells she sells are seashore shells,";
            var msg2b = "\r\nOf that I'm sure.\r\n";

            TcpCommon.DoMsgRoundTrip(msg2a + msg2b, msg2a);

            TcpCommon.DoMsgRoundTrip("\n", "");
            TcpCommon.DoMsgRoundTrip("\r\n", "");
        }
예제 #2
0
 static public void TestConnectionIPv6()
 {
     TcpCommon.DoMsgRoundTrip("meow\n", "meow");
 }