Пример #1
0
        public void TestCircleNoPrimaryKeyInheritsID()
        {
            //---------------Set up test pack-------------------
            IClassDef shapeClassDef = Shape.GetClassDef();
            //---------------Execute Test ----------------------
            BusinessObject objCircleNoPrimaryKey = new CircleNoPrimaryKey();

            //---------------Test Result -----------------------
            Assert.IsNotNull(shapeClassDef.PrimaryKeyDef);
            Shape parent = (Shape)objCircleNoPrimaryKey;

            Assert.AreEqual(objCircleNoPrimaryKey.ID, parent.ID);
            Assert.AreEqual(objCircleNoPrimaryKey.GetPropertyValue("ShapeID"), parent.GetPropertyValue("ShapeID"));
        }
 public void TestCircleNoPrimaryKeyInheritsID()
 {
     //---------------Set up test pack-------------------
     IClassDef shapeClassDef = Shape.GetClassDef();
     //---------------Execute Test ----------------------
     BusinessObject objCircleNoPrimaryKey = new CircleNoPrimaryKey();
     //---------------Test Result -----------------------
     Assert.IsNotNull(shapeClassDef.PrimaryKeyDef);
     Shape parent = (Shape)objCircleNoPrimaryKey;
     Assert.AreEqual(objCircleNoPrimaryKey.ID, parent.ID);
     Assert.AreEqual(objCircleNoPrimaryKey.GetPropertyValue("ShapeID"), parent.GetPropertyValue("ShapeID"));
 }