Пример #1
0
        public void Serialize_CustomCopier()
        {
            var original = new ClassWithCustomCopier()
            {
                IntProperty = 5, StringProperty = "Hello"
            };
            var copy = SerializationManager.DeepCopy(original);

            Assert.AreEqual(1, ClassWithCustomCopier.CopyCounter, "Custom copier was not called");
        }
Пример #2
0
 public void Serialize_CustomCopier()
 {
     var original = new ClassWithCustomCopier() {IntProperty = 5, StringProperty = "Hello"};
     var copy = SerializationManager.DeepCopy(original);
     Assert.AreEqual(1, ClassWithCustomCopier.CopyCounter, "Custom copier was not called");
 }