Beispiel #1
0
        public void after_rejectChanges_service_canRedo_is_false()
        {
            IChangeTrackingService svc = new ChangeTrackingService();

            PersonCollection p = new PersonCollection(svc);

            p.Add(new Person(null, false));

            svc.RejectChanges();

            Assert.IsFalse(svc.CanRedo);
        }
Beispiel #2
0
        public void after_rejectChanges_entity_is_no_more_changed()
        {
            EntityTrackingStates expected = EntityTrackingStates.None;

            ChangeTrackingService svc = new ChangeTrackingService();

            PersonCollection p = new PersonCollection(svc);

            p.Add(new Person(null, false));

            svc.RejectChanges();

            EntityTrackingStates actual = svc.GetEntityState(p);

            Assert.AreEqual <EntityTrackingStates>(expected, actual);
        }