public void MulDataInput() { var packer = new TextPacker(); Exception ex; var data = packer.Input(Encoding.Default.GetBytes("hello"), out ex); Assert.AreEqual(0, data); data = packer.Input(Encoding.Default.GetBytes("helloworld\n"), out ex); Assert.AreEqual(11, data); }
public void InputTests() { var packer = new TextPacker(); Exception ex; var length = packer.Input(Encoding.Default.GetBytes("hello\nworld"), out ex); Assert.AreEqual(6, length); length = packer.Input(Encoding.Default.GetBytes("helloworld"), out ex); Assert.AreEqual(0, length); }