cleaning and adding associations to factories