mirror of
https://github.com/anyproto/anytype-heart.git
synced 2025-06-09 17:44:59 +09:00
GO-4727: Fix some tests
This commit is contained in:
parent
0a4d0550f9
commit
923d5e9b7b
2 changed files with 82 additions and 0 deletions
|
@ -575,6 +575,39 @@ func (_c *MockStore_ReadStoreDoc_Call) RunAndReturn(run func(context.Context, *s
|
|||
return _c
|
||||
}
|
||||
|
||||
// SetDiffManagerOnRemoveHook provides a mock function with given fields: f
|
||||
func (_m *MockStore) SetDiffManagerOnRemoveHook(f func([]string)) {
|
||||
_m.Called(f)
|
||||
}
|
||||
|
||||
// MockStore_SetDiffManagerOnRemoveHook_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SetDiffManagerOnRemoveHook'
|
||||
type MockStore_SetDiffManagerOnRemoveHook_Call struct {
|
||||
*mock.Call
|
||||
}
|
||||
|
||||
// SetDiffManagerOnRemoveHook is a helper method to define mock.On call
|
||||
// - f func([]string)
|
||||
func (_e *MockStore_Expecter) SetDiffManagerOnRemoveHook(f interface{}) *MockStore_SetDiffManagerOnRemoveHook_Call {
|
||||
return &MockStore_SetDiffManagerOnRemoveHook_Call{Call: _e.mock.On("SetDiffManagerOnRemoveHook", f)}
|
||||
}
|
||||
|
||||
func (_c *MockStore_SetDiffManagerOnRemoveHook_Call) Run(run func(f func([]string))) *MockStore_SetDiffManagerOnRemoveHook_Call {
|
||||
_c.Call.Run(func(args mock.Arguments) {
|
||||
run(args[0].(func([]string)))
|
||||
})
|
||||
return _c
|
||||
}
|
||||
|
||||
func (_c *MockStore_SetDiffManagerOnRemoveHook_Call) Return() *MockStore_SetDiffManagerOnRemoveHook_Call {
|
||||
_c.Call.Return()
|
||||
return _c
|
||||
}
|
||||
|
||||
func (_c *MockStore_SetDiffManagerOnRemoveHook_Call) RunAndReturn(run func(func([]string))) *MockStore_SetDiffManagerOnRemoveHook_Call {
|
||||
_c.Call.Return(run)
|
||||
return _c
|
||||
}
|
||||
|
||||
// SetPushChangeHook provides a mock function with given fields: onPushChange
|
||||
func (_m *MockStore) SetPushChangeHook(onPushChange source.PushChangeHook) {
|
||||
_m.Called(onPushChange)
|
||||
|
|
|
@ -5610,6 +5610,55 @@ func (_c *MockClientCommandsServer_ChatGetMessagesByIds_Call) RunAndReturn(run f
|
|||
return _c
|
||||
}
|
||||
|
||||
// ChatReadMessages provides a mock function with given fields: _a0, _a1
|
||||
func (_m *MockClientCommandsServer) ChatReadMessages(_a0 context.Context, _a1 *pb.RpcChatReadRequest) *pb.RpcChatReadResponse {
|
||||
ret := _m.Called(_a0, _a1)
|
||||
|
||||
if len(ret) == 0 {
|
||||
panic("no return value specified for ChatReadMessages")
|
||||
}
|
||||
|
||||
var r0 *pb.RpcChatReadResponse
|
||||
if rf, ok := ret.Get(0).(func(context.Context, *pb.RpcChatReadRequest) *pb.RpcChatReadResponse); ok {
|
||||
r0 = rf(_a0, _a1)
|
||||
} else {
|
||||
if ret.Get(0) != nil {
|
||||
r0 = ret.Get(0).(*pb.RpcChatReadResponse)
|
||||
}
|
||||
}
|
||||
|
||||
return r0
|
||||
}
|
||||
|
||||
// MockClientCommandsServer_ChatReadMessages_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ChatReadMessages'
|
||||
type MockClientCommandsServer_ChatReadMessages_Call struct {
|
||||
*mock.Call
|
||||
}
|
||||
|
||||
// ChatReadMessages is a helper method to define mock.On call
|
||||
// - _a0 context.Context
|
||||
// - _a1 *pb.RpcChatReadRequest
|
||||
func (_e *MockClientCommandsServer_Expecter) ChatReadMessages(_a0 interface{}, _a1 interface{}) *MockClientCommandsServer_ChatReadMessages_Call {
|
||||
return &MockClientCommandsServer_ChatReadMessages_Call{Call: _e.mock.On("ChatReadMessages", _a0, _a1)}
|
||||
}
|
||||
|
||||
func (_c *MockClientCommandsServer_ChatReadMessages_Call) Run(run func(_a0 context.Context, _a1 *pb.RpcChatReadRequest)) *MockClientCommandsServer_ChatReadMessages_Call {
|
||||
_c.Call.Run(func(args mock.Arguments) {
|
||||
run(args[0].(context.Context), args[1].(*pb.RpcChatReadRequest))
|
||||
})
|
||||
return _c
|
||||
}
|
||||
|
||||
func (_c *MockClientCommandsServer_ChatReadMessages_Call) Return(_a0 *pb.RpcChatReadResponse) *MockClientCommandsServer_ChatReadMessages_Call {
|
||||
_c.Call.Return(_a0)
|
||||
return _c
|
||||
}
|
||||
|
||||
func (_c *MockClientCommandsServer_ChatReadMessages_Call) RunAndReturn(run func(context.Context, *pb.RpcChatReadRequest) *pb.RpcChatReadResponse) *MockClientCommandsServer_ChatReadMessages_Call {
|
||||
_c.Call.Return(run)
|
||||
return _c
|
||||
}
|
||||
|
||||
// ChatSubscribeLastMessages provides a mock function with given fields: _a0, _a1
|
||||
func (_m *MockClientCommandsServer) ChatSubscribeLastMessages(_a0 context.Context, _a1 *pb.RpcChatSubscribeLastMessagesRequest) *pb.RpcChatSubscribeLastMessagesResponse {
|
||||
ret := _m.Called(_a0, _a1)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue