

@pytest.mark.skipif("sys.platform == 'win32'")
def test_detect_symlink_dirs(self, monkeypatch, tmpdir):
    monkeypatch.setattr(pip.req.req_uninstall, 'is_local', (lambda p: True))
    d = tmpdir.join('dir')
    d.mkdir()
    dlink = tmpdir.join('dirlink')
    os.symlink(d, dlink)
    d.join('file').touch()
    path1 = str(d.join('file'))
    path2 = str(dlink.join('file'))
    ups = UninstallPathSet(dist=Mock())
    ups.add(path1)
    ups.add(path2)
    assert (ups.paths == set([path1]))

dataset/ETHPy150Open pypa/pip/tests/unit/test_req_uninstall.py TestUninstallPathSet.test_detect_symlink_dirs/original