fixed the code and added/updated the tests