Example #1
0
        public void Clone_FieldsWithSameEnums()
        {
            var orig = new SettingsF();

            orig.Enum = EnumNumbers.One;

            var copy = new SettingsF();

            copy.Enum = EnumNumbers.Two;

            copy.CopyValuesFrom(orig);

            Assert.AreEqual(EnumNumbers.One, copy.Enum);
        }
Example #2
0
        public void Clone_FieldsWithDifferentEnums()
        {
            var orig = new SettingsF();

            orig.Enum = EnumNumbers.One;

            var copy = new SettingsG();

            copy.Enum = EnumColors.Red;

            copy.CopyValuesFrom(orig);

            Assert.AreEqual(EnumColors.Red, copy.Enum);
        }