Documentation ¶
Index ¶
- Variables
- type MockClient
- func (c *MockClient) MockCancelBuilds(buildID int64, summaryMarkdown string, rv *buildbucketpb.BatchResponse, ...)
- func (c *MockClient) MockGetBuild(id int64, rv *buildbucketpb.Build, rvErr error)
- func (c *MockClient) MockGetTrybotsForCL(issueID, patchsetID int64, gerritUrl string, rv []*buildbucketpb.Build, ...)
- func (c *MockClient) MockScheduleBuilds(b, tagName, tagValue, gerritURL, repo, bbProject, bbBucket string, ...)
- func (c *MockClient) MockSearchBuilds(pred *buildbucketpb.BuildPredicate, rv []*buildbucketpb.Build, rvErr error)
- func (c *MockClient) MockStartBuild(buildId int64, taskId string, rv *buildbucketpb.StartBuildResponse, ...)
Constants ¶
This section is empty.
Variables ¶
View Source
var MockBBURL = "mock-buildbucket.appspot.com"
Functions ¶
This section is empty.
Types ¶
type MockClient ¶
type MockClient struct { *buildbucket.Client // contains filtered or unexported fields }
MockClient is a wrapper around Client which doesn't actually perform API calls but instead simply returns mock results. Call any of the Mock* methods before calling the corresponding method on Client, and the mocked result will be returned.
func NewMockClient ¶
func NewMockClient(t sktest.TestingT) *MockClient
func (*MockClient) MockCancelBuilds ¶
func (c *MockClient) MockCancelBuilds(buildID int64, summaryMarkdown string, rv *buildbucketpb.BatchResponse, rvErr error)
func (*MockClient) MockGetBuild ¶
func (c *MockClient) MockGetBuild(id int64, rv *buildbucketpb.Build, rvErr error)
func (*MockClient) MockGetTrybotsForCL ¶
func (c *MockClient) MockGetTrybotsForCL(issueID, patchsetID int64, gerritUrl string, rv []*buildbucketpb.Build, rvErr error)
func (*MockClient) MockScheduleBuilds ¶
func (c *MockClient) MockScheduleBuilds(b, tagName, tagValue, gerritURL, repo, bbProject, bbBucket string, issue, patchset int64, rv *buildbucketpb.BatchResponse, rvErr error)
func (*MockClient) MockSearchBuilds ¶
func (c *MockClient) MockSearchBuilds(pred *buildbucketpb.BuildPredicate, rv []*buildbucketpb.Build, rvErr error)
func (*MockClient) MockStartBuild ¶
func (c *MockClient) MockStartBuild(buildId int64, taskId string, rv *buildbucketpb.StartBuildResponse, rvErr error)
Click to show internal directories.
Click to hide internal directories.