public void TestDelete()
        {
            var entity =
                new MultiTableEntity
                    {
                        Value1 = "ABC",
                        Value2 = "DEF",
                        Value3 = "GHI"
                    };

            entity.ID = db.MultiTableEntities.Insert(entity, m => m.ID);

            AssertTrue(db.MultiTableEntities.Any(m => m.ID == entity.ID));

            int nDeleted = db.MultiTableEntities.Delete(entity);

            //wicky.start
            //AssertValue(3, nDeleted);
            if (provider.Language.AllowsMultipleCommands)
            {
                AssertValue(3, nDeleted);
            }
            else
            {
                AssertValue(1, nDeleted);
            }
            //wicky.end

            AssertFalse(db.MultiTableEntities.Any(m => m.ID == entity.ID));
        }
Esempio n. 2
0
        public void TestDelete()
        {
            var entity =
                new MultiTableEntity
            {
                Value1 = "ABC",
                Value2 = "DEF",
                Value3 = "GHI"
            };

            entity.ID = db.MultiTableEntities.Insert(entity, m => m.ID);

            AssertTrue(db.MultiTableEntities.Any(m => m.ID == entity.ID));

            int nDeleted = db.MultiTableEntities.Delete(entity);

            //wicky.start
            //AssertValue(3, nDeleted);
            if (provider.Language.AllowsMultipleCommands)
            {
                AssertValue(3, nDeleted);
            }
            else
            {
                AssertValue(1, nDeleted);
            }
            //wicky.end

            AssertFalse(db.MultiTableEntities.Any(m => m.ID == entity.ID));
        }
Esempio n. 3
0
        public void TestDelete()
        {
            var entity =
                new MultiTableEntity {
                Value1 = "ABC",
                Value2 = "DEF",
                Value3 = "GHI"
            };

            entity.ID = db.MultiTableEntities.Insert(entity, m => m.ID);

            Assert.Equal(true, db.MultiTableEntities.Any(m => m.ID == entity.ID));

            var nDeleted = db.MultiTableEntities.Delete(entity);

            Assert.Equal(3, nDeleted);

            Assert.Equal(false, db.MultiTableEntities.Any(m => m.ID == entity.ID));
        }
Esempio n. 4
0
        public void TestDelete()
        {
            var entity =
                new MultiTableEntity
                    {
                        Value1 = "ABC",
                        Value2 = "DEF",
                        Value3 = "GHI"
                    };

            entity.ID = db.MultiTableEntities.Insert(entity, m => m.ID);

            AssertTrue(db.MultiTableEntities.Any(m => m.ID == entity.ID));

            int nDeleted = db.MultiTableEntities.Delete(entity);

            AssertValue(3, nDeleted);

            AssertFalse(db.MultiTableEntities.Any(m => m.ID == entity.ID));
        }
Esempio n. 5
0
        public void TestDelete()
        {
            var entity =
                new MultiTableEntity
            {
                Value1 = "ABC",
                Value2 = "DEF",
                Value3 = "GHI"
            };

            entity.ID = db.MultiTableEntities.Insert(entity, m => m.ID);

            AssertTrue(db.MultiTableEntities.Any(m => m.ID == entity.ID));

            int nDeleted = db.MultiTableEntities.Delete(entity);

            AssertValue(3, nDeleted);

            AssertFalse(db.MultiTableEntities.Any(m => m.ID == entity.ID));
        }