public void TestEncoder() { String expected = "1234"; ProtocolCodecSession session = new ProtocolCodecSession(); IProtocolEncoderOutput output = session.EncoderOutput; IProtocolEncoder encoder = new ObjectSerializationEncoder(); encoder.Encode(session, expected, output); Assert.AreEqual(1, session.EncoderOutputQueue.Count); IoBuffer buf = (IoBuffer)session.EncoderOutputQueue.Dequeue(); TestDecoderAndInputStream(expected, buf); }