Added in collection API tests. Cleaned up a bunch of pep8 errors.