Example #1
0
        public void CanCopyPublicProperties()
        {
            var c = new ClassWithPublicProperties();

            c.IntProp    = 2;
            c.StringProp = "string";

            var newC = c.ShallowCopy();

            Assert.Equal(c.IntProp, newC.IntProp);
            Assert.Equal(c.StringProp, newC.StringProp);
        }
Example #2
0
        public void CanCopyPublicProperties() {
            var c = new ClassWithPublicProperties();
            c.IntProp = 2;
            c.StringProp = "string";

            var newC = c.ShallowCopy();
            Assert.Equal(c.IntProp, newC.IntProp);
            Assert.Equal(c.StringProp, newC.StringProp);
        }