Cleaned tests file to correct all pyflakes and pep8 errors

I am -1 to keeping commented out code in the codebase.