MCPcopy Create free account
hub / github.com/cli/cli / StubIssueRepoInfoResponse

Method StubIssueRepoInfoResponse

pkg/httpmock/legacy.go:32–44  ·  view source on GitHub ↗
(owner, repo string)

Source from the content-addressed store, hash-verified

30}
31
32func (r *Registry) StubIssueRepoInfoResponse(owner, repo string) {
33 r.Register(
34 GraphQL(`query IssueRepositoryInfo\b`),
35 StringResponse(fmt.Sprintf(`
36 { "data": { "repository": {
37 "id": "REPOID",
38 "name": "%s",
39 "owner": {"login": "%s"},
40 "hasIssuesEnabled": true,
41 "viewerPermission": "WRITE"
42 } } }
43 `, repo, owner)))
44}
45
46func (r *Registry) StubRepoResponse(owner, repo string) {
47 r.StubRepoResponseWithPermission(owner, repo, "WRITE")

Callers 3

TestIssueCreate_metadataFunction · 0.95

Calls 3

RegisterMethod · 0.95
GraphQLFunction · 0.85
StringResponseFunction · 0.85

Tested by 3

TestIssueCreate_metadataFunction · 0.76