python类PthDistributions()的实例源码

test_easy_install.py 文件源码 项目:BD_T2 作者: jfmolano1587 项目源码 文件源码 阅读 23 收藏 0 点赞 0 评论 0
def test_add_from_cwd_site_sets_dirty(self):
        '''a pth file manager should set dirty
        if a distribution is in site but also the cwd
        '''
        pth = PthDistributions('does-not_exist', [os.getcwd()])
        self.assertTrue(not pth.dirty)
        pth.add(PRDistribution(os.getcwd()))
        self.assertTrue(pth.dirty)
test_easy_install.py 文件源码 项目:BD_T2 作者: jfmolano1587 项目源码 文件源码 阅读 19 收藏 0 点赞 0 评论 0
def test_add_from_site_is_ignored(self):
        if os.name != 'nt':
            location = '/test/location/does-not-have-to-exist'
        else:
            location = 'c:\\does_not_exist'
        pth = PthDistributions('does-not_exist', [location, ])
        self.assertTrue(not pth.dirty)
        pth.add(PRDistribution(location))
        self.assertTrue(not pth.dirty)


问题


面经


文章

微信
公众号

扫码关注公众号