Show More
@@ -314,6 +314,23 b' class _BaseTestApi(object):' | |||||
314 | expected = 'Unable to pull changes from `%s`' % self.REPO |
|
314 | expected = 'Unable to pull changes from `%s`' % self.REPO | |
315 | self._compare_error(id_, expected, given=response.body) |
|
315 | self._compare_error(id_, expected, given=response.body) | |
316 |
|
316 | |||
|
317 | def test_api_pull_custom_remote(self): | |||
|
318 | repo_name = u'test_pull_custom_remote' | |||
|
319 | fixture.create_repo(repo_name, repo_type=self.REPO_TYPE) | |||
|
320 | ||||
|
321 | custom_remote_path = os.path.join(Ui.get_by_key('paths', '/').ui_value, self.REPO) | |||
|
322 | ||||
|
323 | id_, params = _build_data(self.apikey, 'pull', | |||
|
324 | repoid=repo_name, | |||
|
325 | clone_uri=custom_remote_path) | |||
|
326 | response = api_call(self, params) | |||
|
327 | ||||
|
328 | expected = {'msg': 'Pulled from `%s`' % repo_name, | |||
|
329 | 'repository': repo_name} | |||
|
330 | self._compare_ok(id_, expected, given=response.body) | |||
|
331 | ||||
|
332 | fixture.destroy_repo(repo_name) | |||
|
333 | ||||
317 | def test_api_rescan_repos(self): |
|
334 | def test_api_rescan_repos(self): | |
318 | id_, params = _build_data(self.apikey, 'rescan_repos') |
|
335 | id_, params = _build_data(self.apikey, 'rescan_repos') | |
319 | response = api_call(self, params) |
|
336 | response = api_call(self, params) |
General Comments 0
You need to be logged in to leave comments.
Login now