protected void SetupInheritanceSpecifics() { ClassDef.ClassDefs.Clear(); _classDefShape = Shape.GetClassDef(); _classDefCircleNoPrimaryKey = CircleNoPrimaryKey.GetClassDef(); _classDefCircleNoPrimaryKey.SuperClassDef = new SuperClassDef(_classDefShape, ORMapping.SingleTableInheritance); _classDefCircleNoPrimaryKey.SuperClassDef.Discriminator = "ShapeType_field"; _classDefFilledCircleNoPrimaryKey = FilledCircleNoPrimaryKey.GetClassDef(); _classDefFilledCircleNoPrimaryKey.SuperClassDef = new SuperClassDef(_classDefCircleNoPrimaryKey, ORMapping.SingleTableInheritance); _classDefFilledCircleNoPrimaryKey.SuperClassDef.Discriminator = "ShapeType_field"; }
public void TestFilledCircleIsUsingSingleTableInheritance() { Assert.AreEqual(ORMapping.SingleTableInheritance, CircleNoPrimaryKey.GetClassDef().SuperClassDef.ORMapping); Assert.AreEqual(ORMapping.SingleTableInheritance, FilledCircleNoPrimaryKey.GetClassDef().SuperClassDef.ORMapping); }