@@ -1415,6 +1415,36 @@ def closes_issues(self, **kwargs):
1415
1415
(self .project_id , self .id ))
1416
1416
return self .gitlab ._raw_list (url , ProjectIssue , ** kwargs )
1417
1417
1418
+ def commits (self , ** kwargs ):
1419
+ """List the merge request commits.
1420
+
1421
+ Returns:
1422
+ list (ProjectCommit): List of commits
1423
+
1424
+ Raises:
1425
+ GitlabConnectionError: If the server cannot be reached.
1426
+ GitlabListError: If the server fails to perform the request.
1427
+ """
1428
+ url = ('/projects/%s/merge_requests/%s/commits' %
1429
+ (self .project_id , self .id ))
1430
+ return self .gitlab ._raw_list (url , ProjectCommit , ** kwargs )
1431
+
1432
+ def changes (self , ** kwargs ):
1433
+ """List the merge request changes.
1434
+
1435
+ Returns:
1436
+ list (dict): List of changes
1437
+
1438
+ Raises:
1439
+ GitlabConnectionError: If the server cannot be reached.
1440
+ GitlabListError: If the server fails to perform the request.
1441
+ """
1442
+ url = ('/projects/%s/merge_requests/%s/commits' %
1443
+ (self .project_id , self .id ))
1444
+ r = self .gitlab ._raw_get (url , ** kwargs )
1445
+ raise_error_from_response (r , GitlabListError )
1446
+ return r .json ()
1447
+
1418
1448
def merge (self , merge_commit_message = None ,
1419
1449
should_remove_source_branch = False ,
1420
1450
merged_when_build_succeeds = False ,
0 commit comments