DoMsgRoundTrip() public static method

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
return void
Exemplo n.º 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", "");
        }
Exemplo n.º 2
0
 static public void TestConnectionIPv6()
 {
     TcpCommon.DoMsgRoundTrip("meow\n", "meow");
 }