How to automate relationship testing in Doctrine2 entities and mappings?

We have created what we term functional tests for every top level entity to test the relationships of child entities to that one. Basically a top level entity is instantiated and mock data is used to populate it then all its entity dependencies are added themselves being populated with mock data. This is all then persisted to the database in one operation.

The entity is then read back from the database and the tested for equality against the original data. It's a bit more complicated than that (especially the equality test) but if any of the relationship mappings are ever changed or bugged this test immediately fails and give us a que to investigate.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions