added foreign key restraints for yii testing