示例#1
0
    def test_calls_delete_resource(self, mock_delete_by):
        resource = RepoDistributor.build_resource_tag(self.repo,
                                                      self.distributor)

        RepoPublishScheduleManager.delete_by_distributor_id(
            self.repo, self.distributor)

        mock_delete_by.assert_called_once_with(resource)
示例#2
0
    def test_calls_delete_resource(self, mock_delete_by):
        resource = RepoDistributor.build_resource_tag(self.repo, self.distributor)

        RepoPublishScheduleManager.delete_by_distributor_id(self.repo, self.distributor)

        mock_delete_by.assert_called_once_with(resource)
示例#3
0
文件: test_repo.py 项目: pcreech/pulp
 def test_calls_delete_resource(self, m_dist_qs, mock_delete_by):
     RepoPublishScheduleManager.delete_by_distributor_id(self.repo, self.distributor)
     distributor = m_dist_qs.get_or_404.return_value
     mock_delete_by.assert_called_once_with(distributor.resource_tag)