Fix two failing tests on Mac OS X with python2.7.4