Fix shutil.which() test for issue #16993.