diff options
author | 2012-03-04 23:45:43 +0100 | |
---|---|---|
committer | 2012-03-04 23:45:43 +0100 | |
commit | b928c9faf8d2b57afdf32cb233ec83bf3d6a7329 (patch) | |
tree | 8285c7e95adb6755c98f44bae6a6861cc6f03a88 /pygithub3/tests/services/test_repos.py | |
parent | Get repository's commits supported with new result (diff) | |
download | python-github3-b928c9faf8d2b57afdf32cb233ec83bf3d6a7329.tar.xz python-github3-b928c9faf8d2b57afdf32cb233ec83bf3d6a7329.zip |
Fix requests with invalid config precedence
Diffstat (limited to 'pygithub3/tests/services/test_repos.py')
-rw-r--r-- | pygithub3/tests/services/test_repos.py | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/pygithub3/tests/services/test_repos.py b/pygithub3/tests/services/test_repos.py index fd15fe9..e77cc90 100644 --- a/pygithub3/tests/services/test_repos.py +++ b/pygithub3/tests/services/test_repos.py @@ -30,18 +30,12 @@ class TestRepoService(TestCase): self.rs.list().all() self.assertEqual(request_method.call_args[0], ('get', _('user/repos'))) - def test_LIST_with_user_in_args(self, request_method): + def test_LIST_with_user(self, request_method): request_method.return_value = mock_response_result() self.rs.list('octoc').all() self.assertEqual(request_method.call_args[0], ('get', _('users/octoc/repos'))) - def test_LIST_with_user_in_service(self, request_method): - request_method.return_value = mock_response_result() - self.rs.list().all() - self.assertEqual(request_method.call_args[0], - ('get', _('users/octocat/repos'))) - def test_LIST_filters(self, request_method): request_method.return_value = mock_response_result() self.rs.list('octoc', type='public').all() @@ -340,14 +334,13 @@ class TestWatchersService(TestCase): request_method.return_value = mock_response_result() self.ws.list_repos().all() self.assertEqual(request_method.call_args[0], - ('get', _('users/oct/watched'))) + ('get', _('user/watched'))) - def test_LIST_repos_without_user(self, request_method): + def test_LIST_repos_with_user(self, request_method): request_method.return_value = mock_response_result() - self.ws.set_user(None) - self.ws.list_repos().all() + self.ws.list_repos('oct').all() self.assertEqual(request_method.call_args[0], - ('get', _('user/watched'))) + ('get', _('users/oct/watched'))) def test_IS_watching(self, request_method): request_method.return_value = mock_response() |