Refactored setup.py to support testing for different Python versions.