Fix py2/3 tests and better support python 3

only thing outside of correcting tests is using relative imports where possible