Exemplo n.º 1
0
        public async Task SendReceivePortal_Delete()
        {
            editObject = await portal.Fetch();

            editObject.Delete();
            await portal.Update(editObject);

            Assert.IsTrue(editObject.DeleteCalled);
        }
        public async Task SendReceivePortalChild_DeleteChild_Create()
        {
            // Want it to do nothing
            editObject = await portal.CreateChild();

            editObject.Delete();
            await portal.UpdateChild(editObject);

            Assert.IsFalse(editObject.DeleteChildCalled);
        }
Exemplo n.º 3
0
        public async Task SendReceivePortal_DeleteIntCriteriaCalled()
        {
            int crit = DateTime.Now.Millisecond;

            editObject = await portal.Fetch();

            editObject.Delete();
            await portal.Update(editObject, crit);

            Assert.IsTrue(editObject.DeleteCalled);
            Assert.AreEqual(crit, editObject.IntCriteria);
        }
Exemplo n.º 4
0
        public async Task SendReceivePortal_DeleteGuidCriteriaCalled()
        {
            var crit = Guid.NewGuid();

            editObject = await portal.Fetch();

            editObject.Delete();
            await portal.Update(editObject, crit);

            Assert.IsTrue(editObject.DeleteCalled);
            Assert.AreEqual(crit, editObject.GuidCriteria);
        }
Exemplo n.º 5
0
        public void FatClientEdit_IsDeleted()
        {
            target.Delete();

            var json = Serialize(target);

            var newTarget = Deserialize(json);

            Assert.IsTrue(target.IsDeleted);
            Assert.IsTrue(target.IsModified);
            Assert.IsTrue(target.IsSelfModified);
            Assert.IsTrue(newTarget.IsDeleted);
            Assert.IsTrue(newTarget.IsModified);
            Assert.IsTrue(newTarget.IsSelfModified);
        }