public void StructWithEmptyMethods() { byte[] bytes = MessagePackingTest.PackToByteArray(new StructWithEmptyMethodMessage { IntValue = 1, StringValue = "2", DoubleValue = 3.3 }); StructWithEmptyMethodMessage message = MessagePackingTest.UnpackFromByteArray <StructWithEmptyMethodMessage>(bytes); Assert.AreEqual(1, message.IntValue); Assert.AreEqual("2", message.StringValue); Assert.AreEqual(3.3, message.DoubleValue); }
public void StructWithEmptyMethods() { byte[] arr = MessagePackingTest.PackToByteArray(new StructWithEmptyMethodMessage { IntValue = 1, StringValue = "2", DoubleValue = 3.3 }); StructWithEmptyMethodMessage t = MessagePackingTest.UnpackFromByteArray <StructWithEmptyMethodMessage>(arr); Assert.AreEqual(1, t.IntValue); Assert.AreEqual("2", t.StringValue); Assert.AreEqual(3.3, t.DoubleValue); }
public void StructWithEmptyMethods() { byte[] arr = MessagePacker.Pack(new StructWithEmptyMethodMessage { IntValue = 1, StringValue = "2", DoubleValue = 3.3 }); StructWithEmptyMethodMessage t = MessagePacker.Unpack <StructWithEmptyMethodMessage>(arr); Assert.AreEqual(1, t.IntValue); Assert.AreEqual("2", t.StringValue); Assert.AreEqual(3.3, t.DoubleValue); }