fix tests under python 2.6