clean up warnings and get all tests passing