Creating nested test data
Author: Mateusz Koteja
Problem context
In application we had to create organizations, that have users. Organizations can have more organizations underneath. Each organization can have sites, and sites have assets. Also, organization to organization relation is defined by organization-membership entity, and user to organization relation is defined by user-membership entity.
It's a lot of entities to create manually if we want to setup some hierarchy in each test.