Fix the isinstancemethod function's doctest to work on Python 2 and 3.