summaryrefslogtreecommitdiff
path: root/gitlab/tests/test_gitlab.py
diff options
context:
space:
mode:
authorGauvain Pocentek <gauvain.pocentek@objectif-libre.com>2015-05-12 12:50:56 +0200
committerGauvain Pocentek <gauvain.pocentek@objectif-libre.com>2015-05-12 12:50:56 +0200
commitc2d1f8e4e9fe5d94076da8bc836a99b89f6fe9af (patch)
tree7f4e5c7cb5a990df9fefe639af2eaece56bca643 /gitlab/tests/test_gitlab.py
parent0032d468b5dc93b5bf9e639f382b4c869c5ef14c (diff)
downloadgitlab-c2d1f8e4e9fe5d94076da8bc836a99b89f6fe9af.tar.gz
use more pythonic names for some methods
Diffstat (limited to 'gitlab/tests/test_gitlab.py')
-rw-r--r--gitlab/tests/test_gitlab.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/gitlab/tests/test_gitlab.py b/gitlab/tests/test_gitlab.py
index 0c7687c..dc23408 100644
--- a/gitlab/tests/test_gitlab.py
+++ b/gitlab/tests/test_gitlab.py
@@ -450,8 +450,8 @@ class TestGitLab(unittest.TestCase):
email="testuser@test.com", password="testpassword",
ssl_verify=True)
- def test_setUrl(self):
- self.gl.setUrl("http://new_url")
+ def test_set_url(self):
+ self.gl.set_url("http://new_url")
self.assertEqual(self.gl._url, "http://new_url/api/v3")
def test_set_token(self):
@@ -532,7 +532,7 @@ class TestGitLab(unittest.TestCase):
self.assertEqual(self.gl.user.id, id_)
self.assertEqual(type(self.gl.user), CurrentUser)
- def test_getListOrObject_without_id(self):
+ def test_get_list_or_object_without_id(self):
@urlmatch(scheme="http", netloc="localhost", path="/api/v3/projects",
method="get")
def resp_cont(url, request):
@@ -541,13 +541,13 @@ class TestGitLab(unittest.TestCase):
return response(200, content, headers, None, 5, request)
with HTTMock(resp_cont):
- projs = Project._getListOrObject(self.gl, None)
+ projs = Project._get_list_or_object(self.gl, None)
self.assertEqual(len(projs), 1)
proj = projs[0]
self.assertEqual(proj.id, 1)
self.assertEqual(proj.name, "testproject")
- def test_getListOrObject_with_id(self):
+ def test_get_list_or_object_with_id(self):
@urlmatch(scheme="http", netloc="localhost", path="/api/v3/projects/1",
method="get")
def resp_cont(url, request):
@@ -556,7 +556,7 @@ class TestGitLab(unittest.TestCase):
return response(200, content, headers, None, 5, request)
with HTTMock(resp_cont):
- proj = Project._getListOrObject(self.gl, 1)
+ proj = Project._get_list_or_object(self.gl, 1)
self.assertEqual(proj.id, 1)
self.assertEqual(proj.name, "testproject")