Hello out there,
the last few days we kept our-self busy with Design Patterns and how we should apply them to our code. Basically what we did was rewriting our test code, so we would use a Factory taking care of creating instances of our classes.
What we changed now is replacing the code with factories, so we would not have to care about the instantiation of the models.
The actual factories are defined in a separate PHP file but since this doesn’t belong to a class it can’t be displayed in the class diagram.
Basically the code now looks much cleaner and improves the maintainability (you don’t have to change the code at five different locations => DRY).