def test_extract_pkgs(self):
    constructor('--prefix', TestInstall.root_prefix, '--extract-conda-pkgs')
    for pkg in self.pkgs:
        extracted_pkg = os.path.join(TestInstall.root_prefix, 'pkgs', pkg.rsplit('.tar.bz2')[0])
        with open(os.path.join(extracted_pkg, 'info', 'repodata_record.json')) as rr:
            repodata_record = json.load(rr)
        with open(os.path.join(extracted_pkg, 'info', 'index.json')) as ri:
            index = json.load(ri)
        assert (repodata_record['fn'] == pkg)
        assert (repodata_record['md5'] == '123412341234')
        assert (repodata_record['url'] == ('http://testurl.com/conda-forge/linux-64/' + pkg))
        assert (repodata_record['depends'] == index['depends'])
def test_extract_pkgs(self):
    constructor('--prefix', TestInstall.root_prefix, '--extract-conda-pkgs')
    for pkg in self.pkgs:
        extracted_pkg = os.path.join(TestInstall.root_prefix, 'pkgs', pkg.rsplit('.tar.bz2')[0])
        with open(os.path.join(extracted_pkg, 'info', 'repodata_record.json')) as rr:
            repodata_record = json.load(rr)
        with open(os.path.join(extracted_pkg, 'info', 'index.json')) as ri:
            index = json.load(ri)
        assert (repodata_record['fn'] == pkg)
        assert (repodata_record['md5'] == '123412341234')
        assert (repodata_record['url'] == ('http://testurl.com/conda-forge/linux-64/' + pkg))
        assert (repodata_record['depends'] == index['depends'])