Added unit and acceptance tests