housekeeping for entities and tests