Fix Python3 tests