Use os.path.realpath() to output of mkdtemp to fix problem running OSX tests