Fix test failure in Python 2.6