Fix some doctests for Python 2