added junit testing and models