Пример #1
0
        public void SetValueAtEventArgs_ctor_default_values()
        {
            string expectedOldValue = "Old Foo";
            string expectedNewValue = "New Foo";
            int expectedIndex = 10;

            SetValueAtEventArgs<string> obj = new SetValueAtEventArgs<string>( expectedIndex, expectedNewValue, expectedOldValue );

            Assert.IsFalse( obj.Cancel );
            Assert.AreEqual<int>( expectedIndex, obj.Index );
            Assert.AreEqual<string>( expectedNewValue, obj.NewValue );
            Assert.AreEqual<string>( expectedOldValue, obj.OldValue );
        }
Пример #2
0
        public void SetValueAtEventArgs_ctor_default_values()
        {
            string expectedOldValue = "Old Foo";
            string expectedNewValue = "New Foo";
            int    expectedIndex    = 10;

            SetValueAtEventArgs <string> obj = new SetValueAtEventArgs <string>(expectedIndex, expectedNewValue, expectedOldValue);

            Assert.IsFalse(obj.Cancel);
            Assert.AreEqual <int>(expectedIndex, obj.Index);
            Assert.AreEqual <string>(expectedNewValue, obj.NewValue);
            Assert.AreEqual <string>(expectedOldValue, obj.OldValue);
        }