PushFrame() 공개 메소드

public PushFrame ( [ frame ) : void
frame [
리턴 void
예제 #1
0
        public void ReceiveFrameBytesSingleFrame()
        {
            var expected = m_socket.PushFrame("Hello");

            byte[] actual = m_socket.ReceiveFrameBytes();

            Assert.True(actual.SequenceEqual(expected));
            Assert.Equal(SendReceiveConstants.InfiniteTimeout, m_socket.LastTimeout);

            // The buffer is copied into a new array
            Assert.NotSame(expected, actual);
        }
 private byte[] PushFrame([NotNull] string hello)
 {
     byte[] expected = Encoding.ASCII.GetBytes(hello);
     m_socket.PushFrame(expected);
     return(expected);
 }