modify tests so that they'll work on python earlier than 3.1