pep8, test and docs changes