зеркало из https://github.com/mislav/hub.git
Fix requesting pull request reviewers
The expected HTTP status code is 201 Fixes #1463
This commit is contained in:
Родитель
6a48391668
Коммит
e3ad4ef7e5
|
@ -745,6 +745,7 @@ BODY
|
|||
post('/repos/mislav/coral/pulls/1234/requested_reviewers') {
|
||||
halt 415 unless request.accept?('application/vnd.github.black-cat-preview+json')
|
||||
assert :reviewers => ["mislav", "josh", "pcorpet"]
|
||||
status 201
|
||||
json :html_url => "the://url"
|
||||
}
|
||||
"""
|
||||
|
|
|
@ -141,7 +141,7 @@ func (client *Client) RequestReview(project *Project, prNumber int, params map[s
|
|||
}
|
||||
|
||||
res, err := api.PostReview(fmt.Sprintf("repos/%s/%s/pulls/%d/requested_reviewers", project.Owner, project.Name, prNumber), params)
|
||||
if err = checkStatus(200, "requesting reviewer", res, err); err != nil {
|
||||
if err = checkStatus(201, "requesting reviewer", res, err); err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче