Tests updated to work with Python 3