Пример #1
0
        public void WriteRead_SpecificType_EnsureDeserializedProperly()
        {
            SimpleCustomType obj = new SimpleCustomType { BoolProperty = false };
            MemoryStream stream = new MemoryStream();
            Serializer.Write(stream, obj);
            SimpleCustomType deserialized = Serializer.Read<SimpleCustomType>(new MemoryStream(stream.ToArray()));

            Assert.Equal(obj, deserialized);
        }
Пример #2
0
 protected bool Equals(SimpleCustomType other)
 {
     return BoolProperty.Equals(other.BoolProperty);
 }