'Cascade deletion works with ForeignKey.to_field set to non-PK.'

def test_to_field(self):

    apple = Food.objects.create(name='apple')
    Eaten.objects.create(food=apple, meal='lunch')
    apple.delete()
    self.assertFalse(Food.objects.exists())
    self.assertFalse(Eaten.objects.exists())
