Exemple #1
0
    def test_delete_raises_httperrors(self):
        self.mock_github_request('foo', '', method='delete', response_status_code=401)
        self.mocker.replay()

        with self.assertRaises(HTTPError) as cm:
            github.delete('foo', StubConfig())

        self.assertEquals('401 Client Error: Unauthorized', str(cm.exception))
 def delete_subscriptions(self, repositories):
     for reponame in repositories:
         logging.info('delete subscription: %s' % reponame)
         github.delete('repos/%s/subscription' % reponame, self.config)
Exemple #3
0
 def delete_subscriptions(self, repositories):
     for reponame in repositories:
         logging.info('delete subscription: %s' % reponame)
         github.delete('repos/%s/subscription' % reponame, self.config)
Exemple #4
0
 def test_delete_request(self):
     self.mock_github_request('foo', '', method='delete')
     self.mocker.replay()
     github.delete('foo', StubConfig())