allow running integration tests on python 3
Python 3 fixes for integration tests