diff options
author | Gauvain Pocentek <gauvain.pocentek@objectif-libre.com> | 2016-01-23 17:07:51 +0100 |
---|---|---|
committer | Gauvain Pocentek <gauvain.pocentek@objectif-libre.com> | 2016-01-23 17:07:51 +0100 |
commit | bf985b30038f8f097c46ab363b82efaab14cfab6 (patch) | |
tree | b544cca522302adff1793661bfd622ce5ede9039 | |
parent | e40d9ac328bc5487ca15d2371399c8dfe3b91c51 (diff) | |
download | gitlab-bf985b30038f8f097c46ab363b82efaab14cfab6.tar.gz |
fix the test_create_unknown_path test
-rw-r--r-- | gitlab/tests/test_gitlab.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/gitlab/tests/test_gitlab.py b/gitlab/tests/test_gitlab.py index 7872083..1f15d30 100644 --- a/gitlab/tests/test_gitlab.py +++ b/gitlab/tests/test_gitlab.py @@ -429,9 +429,8 @@ class TestGitlabMethods(unittest.TestCase): 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", @@ -442,7 +441,7 @@ class TestGitlabMethods(unittest.TestCase): 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"}) |