added nested models, associations, tests