public void ShouldRaiseEventWhenPropertyChanging()
        {
            var target = new PropertyChangingAttributes();
            var raised = false;

            ((INotifyPropertyChanging)target).PropertyChanging += (sender, e) => raised = true;
            target.Text = "Hello world";

            Assert.True(raised);
        }
        public void ShouldNotRaiseEventWhenPropertyChangingAndIsIgnored()
        {
            var target = new PropertyChangingAttributes();
            var raised = false;

            ((INotifyPropertyChanging)target).PropertyChanging += (sender, e) => raised = true;
            target.Id = 2000;

            Assert.False(raised);
        }
        public void ShouldImplementINotifyPropertyChanging()
        {
            var target = new PropertyChangingAttributes();

            Assert.NotNull(target as INotifyPropertyChanging);
        }