summaryrefslogtreecommitdiff
path: root/gitlab/v4/objects.py
diff options
context:
space:
mode:
authorGauvain Pocentek <gauvain@pocentek.net>2017-08-21 11:55:00 +0200
committerGauvain Pocentek <gauvain@pocentek.net>2017-08-21 11:55:00 +0200
commit0e0d4aee3e73e2caf86c50bc9152764528f7725a (patch)
treef56d4c96aec4e17f7d4bb1dc3d1b1f662ea14701 /gitlab/v4/objects.py
parent311464b71c508503d5275db5975bc10ed74674bd (diff)
downloadgitlab-0e0d4aee3e73e2caf86c50bc9152764528f7725a.tar.gz
[v4] More python functional tests
Diffstat (limited to 'gitlab/v4/objects.py')
-rw-r--r--gitlab/v4/objects.py24
1 files changed, 13 insertions, 11 deletions
diff --git a/gitlab/v4/objects.py b/gitlab/v4/objects.py
index d4e9e63..3b1eb91 100644
--- a/gitlab/v4/objects.py
+++ b/gitlab/v4/objects.py
@@ -209,13 +209,13 @@ class UserManager(CRUDMixin, RESTManager):
_obj_cls = User
_list_filters = ('active', 'blocked', 'username', 'extern_uid', 'provider',
- 'external')
+ 'external', 'search')
_create_attrs = (
- ('email', 'username', 'name'),
- ('password', 'reset_password', 'skype', 'linkedin', 'twitter',
- 'projects_limit', 'extern_uid', 'provider', 'bio', 'admin',
- 'can_create_group', 'website_url', 'skip_confirmation', 'external',
- 'organization', 'location')
+ tuple(),
+ ('email', 'username', 'name', 'password', 'reset_password', 'skype',
+ 'linkedin', 'twitter', 'projects_limit', 'extern_uid', 'provider',
+ 'bio', 'admin', 'can_create_group', 'website_url',
+ 'skip_confirmation', 'external', 'organization', 'location')
)
_update_attrs = (
('email', 'username', 'name'),
@@ -730,13 +730,14 @@ class ProjectCommitStatus(RESTObject):
pass
-class ProjectCommitStatusManager(RetrieveMixin, CreateMixin, RESTManager):
+class ProjectCommitStatusManager(GetFromListMixin, CreateMixin, RESTManager):
_path = ('/projects/%(project_id)s/repository/commits/%(commit_id)s'
'/statuses')
_obj_cls = ProjectCommitStatus
_from_parent_attrs = {'project_id': 'project_id', 'commit_id': 'id'}
- _create_attrs = (('state', ),
- ('description', 'name', 'context', 'ref', 'target_url'))
+ _create_attrs = (('state', 'sha'),
+ ('description', 'name', 'context', 'ref', 'target_url',
+ 'coverage'))
def create(self, data, **kwargs):
"""Create a new object.
@@ -761,7 +762,7 @@ class ProjectCommitStatusManager(RetrieveMixin, CreateMixin, RESTManager):
class ProjectCommitComment(RESTObject):
- pass
+ _id_attr = None
class ProjectCommitCommentManager(ListMixin, CreateMixin, RESTManager):
@@ -864,10 +865,11 @@ class ProjectKeyManager(NoUpdateMixin, RESTManager):
class ProjectEvent(RESTObject):
+ _id_attr = None
_short_print_attr = 'target_title'
-class ProjectEventManager(GetFromListMixin, RESTManager):
+class ProjectEventManager(ListMixin, RESTManager):
_path = '/projects/%(project_id)s/events'
_obj_cls = ProjectEvent
_from_parent_attrs = {'project_id': 'id'}