| // Code generated by mockery v0.0.0-dev. (with some manual edits) |
| // |
| // Note: Please be careful autogenerating this file again, as mockery doesn't do a perfect job |
| // of creating a mock grpc server - it doesn't add `v1.UnimplementedCulpritServiceServer` as |
| // part of `CulpritServiceServer`. In case you want to regenerate it, re-add it to |
| // CulpritServiceServer definition. |
| package mocks |
| |
| import ( |
| context "context" |
| |
| mock "github.com/stretchr/testify/mock" |
| v1 "go.skia.org/infra/perf/go/culprit/proto/v1" |
| ) |
| |
| // CulpritServiceServer is an autogenerated mock type for the CulpritServiceServer type |
| type CulpritServiceServer struct { |
| mock.Mock |
| // -----------Line below was added manually----------- |
| v1.UnimplementedCulpritServiceServer |
| } |
| |
| // GetCulprit provides a mock function with given fields: _a0, _a1 |
| func (_m *CulpritServiceServer) GetCulprit(_a0 context.Context, _a1 *v1.GetCulpritRequest) (*v1.GetCulpritResponse, error) { |
| ret := _m.Called(_a0, _a1) |
| |
| if len(ret) == 0 { |
| panic("no return value specified for GetCulprit") |
| } |
| |
| var r0 *v1.GetCulpritResponse |
| var r1 error |
| if rf, ok := ret.Get(0).(func(context.Context, *v1.GetCulpritRequest) (*v1.GetCulpritResponse, error)); ok { |
| return rf(_a0, _a1) |
| } |
| if rf, ok := ret.Get(0).(func(context.Context, *v1.GetCulpritRequest) *v1.GetCulpritResponse); ok { |
| r0 = rf(_a0, _a1) |
| } else { |
| if ret.Get(0) != nil { |
| r0 = ret.Get(0).(*v1.GetCulpritResponse) |
| } |
| } |
| |
| if rf, ok := ret.Get(1).(func(context.Context, *v1.GetCulpritRequest) error); ok { |
| r1 = rf(_a0, _a1) |
| } else { |
| r1 = ret.Error(1) |
| } |
| |
| return r0, r1 |
| } |
| |
| // NotifyUserOfAnomaly provides a mock function with given fields: _a0, _a1 |
| func (_m *CulpritServiceServer) NotifyUserOfAnomaly(_a0 context.Context, _a1 *v1.NotifyUserOfAnomalyRequest) (*v1.NotifyUserOfAnomalyResponse, error) { |
| ret := _m.Called(_a0, _a1) |
| |
| if len(ret) == 0 { |
| panic("no return value specified for NotifyUserOfAnomaly") |
| } |
| |
| var r0 *v1.NotifyUserOfAnomalyResponse |
| var r1 error |
| if rf, ok := ret.Get(0).(func(context.Context, *v1.NotifyUserOfAnomalyRequest) (*v1.NotifyUserOfAnomalyResponse, error)); ok { |
| return rf(_a0, _a1) |
| } |
| if rf, ok := ret.Get(0).(func(context.Context, *v1.NotifyUserOfAnomalyRequest) *v1.NotifyUserOfAnomalyResponse); ok { |
| r0 = rf(_a0, _a1) |
| } else { |
| if ret.Get(0) != nil { |
| r0 = ret.Get(0).(*v1.NotifyUserOfAnomalyResponse) |
| } |
| } |
| |
| if rf, ok := ret.Get(1).(func(context.Context, *v1.NotifyUserOfAnomalyRequest) error); ok { |
| r1 = rf(_a0, _a1) |
| } else { |
| r1 = ret.Error(1) |
| } |
| |
| return r0, r1 |
| } |
| |
| // NotifyUserOfCulprit provides a mock function with given fields: _a0, _a1 |
| func (_m *CulpritServiceServer) NotifyUserOfCulprit(_a0 context.Context, _a1 *v1.NotifyUserOfCulpritRequest) (*v1.NotifyUserOfCulpritResponse, error) { |
| ret := _m.Called(_a0, _a1) |
| |
| if len(ret) == 0 { |
| panic("no return value specified for NotifyUserOfCulprit") |
| } |
| |
| var r0 *v1.NotifyUserOfCulpritResponse |
| var r1 error |
| if rf, ok := ret.Get(0).(func(context.Context, *v1.NotifyUserOfCulpritRequest) (*v1.NotifyUserOfCulpritResponse, error)); ok { |
| return rf(_a0, _a1) |
| } |
| if rf, ok := ret.Get(0).(func(context.Context, *v1.NotifyUserOfCulpritRequest) *v1.NotifyUserOfCulpritResponse); ok { |
| r0 = rf(_a0, _a1) |
| } else { |
| if ret.Get(0) != nil { |
| r0 = ret.Get(0).(*v1.NotifyUserOfCulpritResponse) |
| } |
| } |
| |
| if rf, ok := ret.Get(1).(func(context.Context, *v1.NotifyUserOfCulpritRequest) error); ok { |
| r1 = rf(_a0, _a1) |
| } else { |
| r1 = ret.Error(1) |
| } |
| |
| return r0, r1 |
| } |
| |
| // PersistCulprit provides a mock function with given fields: _a0, _a1 |
| func (_m *CulpritServiceServer) PersistCulprit(_a0 context.Context, _a1 *v1.PersistCulpritRequest) (*v1.PersistCulpritResponse, error) { |
| ret := _m.Called(_a0, _a1) |
| |
| if len(ret) == 0 { |
| panic("no return value specified for PersistCulprit") |
| } |
| |
| var r0 *v1.PersistCulpritResponse |
| var r1 error |
| if rf, ok := ret.Get(0).(func(context.Context, *v1.PersistCulpritRequest) (*v1.PersistCulpritResponse, error)); ok { |
| return rf(_a0, _a1) |
| } |
| if rf, ok := ret.Get(0).(func(context.Context, *v1.PersistCulpritRequest) *v1.PersistCulpritResponse); ok { |
| r0 = rf(_a0, _a1) |
| } else { |
| if ret.Get(0) != nil { |
| r0 = ret.Get(0).(*v1.PersistCulpritResponse) |
| } |
| } |
| |
| if rf, ok := ret.Get(1).(func(context.Context, *v1.PersistCulpritRequest) error); ok { |
| r1 = rf(_a0, _a1) |
| } else { |
| r1 = ret.Error(1) |
| } |
| |
| return r0, r1 |
| } |
| |
| // mustEmbedUnimplementedCulpritServiceServer provides a mock function with given fields: |
| func (_m *CulpritServiceServer) mustEmbedUnimplementedCulpritServiceServer() { |
| _m.Called() |
| } |
| |
| // NewCulpritServiceServer creates a new instance of CulpritServiceServer. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. |
| // The first argument is typically a *testing.T value. |
| func NewCulpritServiceServer(t interface { |
| mock.TestingT |
| Cleanup(func()) |
| }) *CulpritServiceServer { |
| mock := &CulpritServiceServer{} |
| mock.Mock.Test(t) |
| |
| t.Cleanup(func() { mock.AssertExpectations(t) }) |
| |
| return mock |
| } |