Fix Python Test Script for Python 3+

Updating for python 3 (which is the default on most systems now).