(reg *httpmock.Registry, cb func(params map[string]any))
| 475 | } |
| 476 | |
| 477 | func mockSuccessfulEditResponse(reg *httpmock.Registry, cb func(params map[string]any)) { |
| 478 | matcher := httpmock.REST("PATCH", "repos/OWNER/REPO/releases/12345") |
| 479 | responder := httpmock.RESTPayload(201, `{ |
| 480 | "html_url": "https://github.com/OWNER/REPO/releases/tag/v1.2.3" |
| 481 | }`, cb) |
| 482 | reg.Register(matcher, responder) |
| 483 | } |
| 484 | |
| 485 | func Test_editRelease_httpError(t *testing.T) { |
| 486 | reg := &httpmock.Registry{} |
no test coverage detected