updated test to support python 3