tested controllers and added factories

not good practice in a real app tho. but its ok for now.