| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215 |
- // Code generated by mockery v2.53.3. DO NOT EDIT.
- package handler
- import (
- context "context"
- state "github.com/mk6i/retro-aim-server/state"
- mock "github.com/stretchr/testify/mock"
- wire "github.com/mk6i/retro-aim-server/wire"
- )
- // mockAdminService is an autogenerated mock type for the AdminService type
- type mockAdminService struct {
- mock.Mock
- }
- type mockAdminService_Expecter struct {
- mock *mock.Mock
- }
- func (_m *mockAdminService) EXPECT() *mockAdminService_Expecter {
- return &mockAdminService_Expecter{mock: &_m.Mock}
- }
- // ConfirmRequest provides a mock function with given fields: ctx, sess, frame
- func (_m *mockAdminService) ConfirmRequest(ctx context.Context, sess *state.Session, frame wire.SNACFrame) (wire.SNACMessage, error) {
- ret := _m.Called(ctx, sess, frame)
- if len(ret) == 0 {
- panic("no return value specified for ConfirmRequest")
- }
- var r0 wire.SNACMessage
- var r1 error
- if rf, ok := ret.Get(0).(func(context.Context, *state.Session, wire.SNACFrame) (wire.SNACMessage, error)); ok {
- return rf(ctx, sess, frame)
- }
- if rf, ok := ret.Get(0).(func(context.Context, *state.Session, wire.SNACFrame) wire.SNACMessage); ok {
- r0 = rf(ctx, sess, frame)
- } else {
- r0 = ret.Get(0).(wire.SNACMessage)
- }
- if rf, ok := ret.Get(1).(func(context.Context, *state.Session, wire.SNACFrame) error); ok {
- r1 = rf(ctx, sess, frame)
- } else {
- r1 = ret.Error(1)
- }
- return r0, r1
- }
- // mockAdminService_ConfirmRequest_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ConfirmRequest'
- type mockAdminService_ConfirmRequest_Call struct {
- *mock.Call
- }
- // ConfirmRequest is a helper method to define mock.On call
- // - ctx context.Context
- // - sess *state.Session
- // - frame wire.SNACFrame
- func (_e *mockAdminService_Expecter) ConfirmRequest(ctx interface{}, sess interface{}, frame interface{}) *mockAdminService_ConfirmRequest_Call {
- return &mockAdminService_ConfirmRequest_Call{Call: _e.mock.On("ConfirmRequest", ctx, sess, frame)}
- }
- func (_c *mockAdminService_ConfirmRequest_Call) Run(run func(ctx context.Context, sess *state.Session, frame wire.SNACFrame)) *mockAdminService_ConfirmRequest_Call {
- _c.Call.Run(func(args mock.Arguments) {
- run(args[0].(context.Context), args[1].(*state.Session), args[2].(wire.SNACFrame))
- })
- return _c
- }
- func (_c *mockAdminService_ConfirmRequest_Call) Return(_a0 wire.SNACMessage, _a1 error) *mockAdminService_ConfirmRequest_Call {
- _c.Call.Return(_a0, _a1)
- return _c
- }
- func (_c *mockAdminService_ConfirmRequest_Call) RunAndReturn(run func(context.Context, *state.Session, wire.SNACFrame) (wire.SNACMessage, error)) *mockAdminService_ConfirmRequest_Call {
- _c.Call.Return(run)
- return _c
- }
- // InfoChangeRequest provides a mock function with given fields: ctx, sess, frame, body
- func (_m *mockAdminService) InfoChangeRequest(ctx context.Context, sess *state.Session, frame wire.SNACFrame, body wire.SNAC_0x07_0x04_AdminInfoChangeRequest) (wire.SNACMessage, error) {
- ret := _m.Called(ctx, sess, frame, body)
- if len(ret) == 0 {
- panic("no return value specified for InfoChangeRequest")
- }
- var r0 wire.SNACMessage
- var r1 error
- if rf, ok := ret.Get(0).(func(context.Context, *state.Session, wire.SNACFrame, wire.SNAC_0x07_0x04_AdminInfoChangeRequest) (wire.SNACMessage, error)); ok {
- return rf(ctx, sess, frame, body)
- }
- if rf, ok := ret.Get(0).(func(context.Context, *state.Session, wire.SNACFrame, wire.SNAC_0x07_0x04_AdminInfoChangeRequest) wire.SNACMessage); ok {
- r0 = rf(ctx, sess, frame, body)
- } else {
- r0 = ret.Get(0).(wire.SNACMessage)
- }
- if rf, ok := ret.Get(1).(func(context.Context, *state.Session, wire.SNACFrame, wire.SNAC_0x07_0x04_AdminInfoChangeRequest) error); ok {
- r1 = rf(ctx, sess, frame, body)
- } else {
- r1 = ret.Error(1)
- }
- return r0, r1
- }
- // mockAdminService_InfoChangeRequest_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'InfoChangeRequest'
- type mockAdminService_InfoChangeRequest_Call struct {
- *mock.Call
- }
- // InfoChangeRequest is a helper method to define mock.On call
- // - ctx context.Context
- // - sess *state.Session
- // - frame wire.SNACFrame
- // - body wire.SNAC_0x07_0x04_AdminInfoChangeRequest
- func (_e *mockAdminService_Expecter) InfoChangeRequest(ctx interface{}, sess interface{}, frame interface{}, body interface{}) *mockAdminService_InfoChangeRequest_Call {
- return &mockAdminService_InfoChangeRequest_Call{Call: _e.mock.On("InfoChangeRequest", ctx, sess, frame, body)}
- }
- func (_c *mockAdminService_InfoChangeRequest_Call) Run(run func(ctx context.Context, sess *state.Session, frame wire.SNACFrame, body wire.SNAC_0x07_0x04_AdminInfoChangeRequest)) *mockAdminService_InfoChangeRequest_Call {
- _c.Call.Run(func(args mock.Arguments) {
- run(args[0].(context.Context), args[1].(*state.Session), args[2].(wire.SNACFrame), args[3].(wire.SNAC_0x07_0x04_AdminInfoChangeRequest))
- })
- return _c
- }
- func (_c *mockAdminService_InfoChangeRequest_Call) Return(_a0 wire.SNACMessage, _a1 error) *mockAdminService_InfoChangeRequest_Call {
- _c.Call.Return(_a0, _a1)
- return _c
- }
- func (_c *mockAdminService_InfoChangeRequest_Call) RunAndReturn(run func(context.Context, *state.Session, wire.SNACFrame, wire.SNAC_0x07_0x04_AdminInfoChangeRequest) (wire.SNACMessage, error)) *mockAdminService_InfoChangeRequest_Call {
- _c.Call.Return(run)
- return _c
- }
- // InfoQuery provides a mock function with given fields: ctx, sess, frame, body
- func (_m *mockAdminService) InfoQuery(ctx context.Context, sess *state.Session, frame wire.SNACFrame, body wire.SNAC_0x07_0x02_AdminInfoQuery) (wire.SNACMessage, error) {
- ret := _m.Called(ctx, sess, frame, body)
- if len(ret) == 0 {
- panic("no return value specified for InfoQuery")
- }
- var r0 wire.SNACMessage
- var r1 error
- if rf, ok := ret.Get(0).(func(context.Context, *state.Session, wire.SNACFrame, wire.SNAC_0x07_0x02_AdminInfoQuery) (wire.SNACMessage, error)); ok {
- return rf(ctx, sess, frame, body)
- }
- if rf, ok := ret.Get(0).(func(context.Context, *state.Session, wire.SNACFrame, wire.SNAC_0x07_0x02_AdminInfoQuery) wire.SNACMessage); ok {
- r0 = rf(ctx, sess, frame, body)
- } else {
- r0 = ret.Get(0).(wire.SNACMessage)
- }
- if rf, ok := ret.Get(1).(func(context.Context, *state.Session, wire.SNACFrame, wire.SNAC_0x07_0x02_AdminInfoQuery) error); ok {
- r1 = rf(ctx, sess, frame, body)
- } else {
- r1 = ret.Error(1)
- }
- return r0, r1
- }
- // mockAdminService_InfoQuery_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'InfoQuery'
- type mockAdminService_InfoQuery_Call struct {
- *mock.Call
- }
- // InfoQuery is a helper method to define mock.On call
- // - ctx context.Context
- // - sess *state.Session
- // - frame wire.SNACFrame
- // - body wire.SNAC_0x07_0x02_AdminInfoQuery
- func (_e *mockAdminService_Expecter) InfoQuery(ctx interface{}, sess interface{}, frame interface{}, body interface{}) *mockAdminService_InfoQuery_Call {
- return &mockAdminService_InfoQuery_Call{Call: _e.mock.On("InfoQuery", ctx, sess, frame, body)}
- }
- func (_c *mockAdminService_InfoQuery_Call) Run(run func(ctx context.Context, sess *state.Session, frame wire.SNACFrame, body wire.SNAC_0x07_0x02_AdminInfoQuery)) *mockAdminService_InfoQuery_Call {
- _c.Call.Run(func(args mock.Arguments) {
- run(args[0].(context.Context), args[1].(*state.Session), args[2].(wire.SNACFrame), args[3].(wire.SNAC_0x07_0x02_AdminInfoQuery))
- })
- return _c
- }
- func (_c *mockAdminService_InfoQuery_Call) Return(_a0 wire.SNACMessage, _a1 error) *mockAdminService_InfoQuery_Call {
- _c.Call.Return(_a0, _a1)
- return _c
- }
- func (_c *mockAdminService_InfoQuery_Call) RunAndReturn(run func(context.Context, *state.Session, wire.SNACFrame, wire.SNAC_0x07_0x02_AdminInfoQuery) (wire.SNACMessage, error)) *mockAdminService_InfoQuery_Call {
- _c.Call.Return(run)
- return _c
- }
- // newMockAdminService creates a new instance of mockAdminService. 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 newMockAdminService(t interface {
- mock.TestingT
- Cleanup(func())
- }) *mockAdminService {
- mock := &mockAdminService{}
- mock.Mock.Test(t)
- t.Cleanup(func() { mock.AssertExpectations(t) })
- return mock
- }
|