pass all the tests and fix some style issues