Fixed tests on Python 2.5