Skip to content

Commit

Permalink
fix the test_create_unknown_path test
Browse files Browse the repository at this point in the history
  • Loading branch information
Gauvain Pocentek committed Jan 23, 2016
1 parent e40d9ac commit bf985b3
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions gitlab/tests/test_gitlab.py
Expand Up @@ -429,9 +429,8 @@ def test_create_kw_missing(self):
self.assertRaises(GitlabCreateError, self.gl.create, obj)

def test_create_unknown_path(self):
obj = User(self.gl, data={"email": "email", "password": "password",
"username": "username", "name": "name",
"can_create_group": True})
obj = Project(self.gl, data={"name": "name"})
obj.id = 1
obj._from_api = True

@urlmatch(scheme="http", netloc="localhost", path="/api/v3/projects/1",
Expand All @@ -442,7 +441,7 @@ def resp_cont(url, request):
return response(404, content, headers, None, 5, request)

with HTTMock(resp_cont):
self.assertRaises(GitlabCreateError, self.gl.create, obj)
self.assertRaises(GitlabDeleteError, self.gl.delete, obj)

def test_create_401(self):
obj = Group(self.gl, data={"name": "testgroup", "path": "testpath"})
Expand Down

0 comments on commit bf985b3

Please sign in to comment.