Exemplo n.º 1
0
    def setUp(self):
        self.working_dir = tempfile.mkdtemp(prefix='downloader-tests')
        self.repo = Repository('test-repo', working_dir=self.working_dir)

        self.config = PluginCallConfiguration({}, {})

        self.mock_cancelled_callback = mock.MagicMock().is_cancelled
        self.mock_cancelled_callback.return_value = False

        self.mock_progress_report = mock.MagicMock()

        self.dist = samples.get_valid_repo()
        self.pkg = model.Package(**samples.get_data('package'))
Exemplo n.º 2
0
 def setUp(self):
     self.dist = samples.get_valid_repo()
     self.cmpt = self.dist["components"][0]
Exemplo n.º 3
0
 def test_get_indexes(self):
     dist = samples.get_valid_repo()
     indexes = dist.get_indexes()
     self.assertEquals(len(indexes), 3)