| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460 |
- // Code generated by mockery v2.53.3. DO NOT EDIT.
- package toc
- import (
- context "context"
- state "github.com/mk6i/retro-aim-server/state"
- mock "github.com/stretchr/testify/mock"
- uuid "github.com/google/uuid"
- wire "github.com/mk6i/retro-aim-server/wire"
- )
- // mockAuthService is an autogenerated mock type for the AuthService type
- type mockAuthService struct {
- mock.Mock
- }
- type mockAuthService_Expecter struct {
- mock *mock.Mock
- }
- func (_m *mockAuthService) EXPECT() *mockAuthService_Expecter {
- return &mockAuthService_Expecter{mock: &_m.Mock}
- }
- // BUCPChallenge provides a mock function with given fields: ctx, bodyIn, newUUID
- func (_m *mockAuthService) BUCPChallenge(ctx context.Context, bodyIn wire.SNAC_0x17_0x06_BUCPChallengeRequest, newUUID func() uuid.UUID) (wire.SNACMessage, error) {
- ret := _m.Called(ctx, bodyIn, newUUID)
- if len(ret) == 0 {
- panic("no return value specified for BUCPChallenge")
- }
- var r0 wire.SNACMessage
- var r1 error
- if rf, ok := ret.Get(0).(func(context.Context, wire.SNAC_0x17_0x06_BUCPChallengeRequest, func() uuid.UUID) (wire.SNACMessage, error)); ok {
- return rf(ctx, bodyIn, newUUID)
- }
- if rf, ok := ret.Get(0).(func(context.Context, wire.SNAC_0x17_0x06_BUCPChallengeRequest, func() uuid.UUID) wire.SNACMessage); ok {
- r0 = rf(ctx, bodyIn, newUUID)
- } else {
- r0 = ret.Get(0).(wire.SNACMessage)
- }
- if rf, ok := ret.Get(1).(func(context.Context, wire.SNAC_0x17_0x06_BUCPChallengeRequest, func() uuid.UUID) error); ok {
- r1 = rf(ctx, bodyIn, newUUID)
- } else {
- r1 = ret.Error(1)
- }
- return r0, r1
- }
- // mockAuthService_BUCPChallenge_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'BUCPChallenge'
- type mockAuthService_BUCPChallenge_Call struct {
- *mock.Call
- }
- // BUCPChallenge is a helper method to define mock.On call
- // - ctx context.Context
- // - bodyIn wire.SNAC_0x17_0x06_BUCPChallengeRequest
- // - newUUID func() uuid.UUID
- func (_e *mockAuthService_Expecter) BUCPChallenge(ctx interface{}, bodyIn interface{}, newUUID interface{}) *mockAuthService_BUCPChallenge_Call {
- return &mockAuthService_BUCPChallenge_Call{Call: _e.mock.On("BUCPChallenge", ctx, bodyIn, newUUID)}
- }
- func (_c *mockAuthService_BUCPChallenge_Call) Run(run func(ctx context.Context, bodyIn wire.SNAC_0x17_0x06_BUCPChallengeRequest, newUUID func() uuid.UUID)) *mockAuthService_BUCPChallenge_Call {
- _c.Call.Run(func(args mock.Arguments) {
- run(args[0].(context.Context), args[1].(wire.SNAC_0x17_0x06_BUCPChallengeRequest), args[2].(func() uuid.UUID))
- })
- return _c
- }
- func (_c *mockAuthService_BUCPChallenge_Call) Return(_a0 wire.SNACMessage, _a1 error) *mockAuthService_BUCPChallenge_Call {
- _c.Call.Return(_a0, _a1)
- return _c
- }
- func (_c *mockAuthService_BUCPChallenge_Call) RunAndReturn(run func(context.Context, wire.SNAC_0x17_0x06_BUCPChallengeRequest, func() uuid.UUID) (wire.SNACMessage, error)) *mockAuthService_BUCPChallenge_Call {
- _c.Call.Return(run)
- return _c
- }
- // BUCPLogin provides a mock function with given fields: ctx, bodyIn, newUserFn
- func (_m *mockAuthService) BUCPLogin(ctx context.Context, bodyIn wire.SNAC_0x17_0x02_BUCPLoginRequest, newUserFn func(state.DisplayScreenName) (state.User, error)) (wire.SNACMessage, error) {
- ret := _m.Called(ctx, bodyIn, newUserFn)
- if len(ret) == 0 {
- panic("no return value specified for BUCPLogin")
- }
- var r0 wire.SNACMessage
- var r1 error
- if rf, ok := ret.Get(0).(func(context.Context, wire.SNAC_0x17_0x02_BUCPLoginRequest, func(state.DisplayScreenName) (state.User, error)) (wire.SNACMessage, error)); ok {
- return rf(ctx, bodyIn, newUserFn)
- }
- if rf, ok := ret.Get(0).(func(context.Context, wire.SNAC_0x17_0x02_BUCPLoginRequest, func(state.DisplayScreenName) (state.User, error)) wire.SNACMessage); ok {
- r0 = rf(ctx, bodyIn, newUserFn)
- } else {
- r0 = ret.Get(0).(wire.SNACMessage)
- }
- if rf, ok := ret.Get(1).(func(context.Context, wire.SNAC_0x17_0x02_BUCPLoginRequest, func(state.DisplayScreenName) (state.User, error)) error); ok {
- r1 = rf(ctx, bodyIn, newUserFn)
- } else {
- r1 = ret.Error(1)
- }
- return r0, r1
- }
- // mockAuthService_BUCPLogin_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'BUCPLogin'
- type mockAuthService_BUCPLogin_Call struct {
- *mock.Call
- }
- // BUCPLogin is a helper method to define mock.On call
- // - ctx context.Context
- // - bodyIn wire.SNAC_0x17_0x02_BUCPLoginRequest
- // - newUserFn func(state.DisplayScreenName)(state.User , error)
- func (_e *mockAuthService_Expecter) BUCPLogin(ctx interface{}, bodyIn interface{}, newUserFn interface{}) *mockAuthService_BUCPLogin_Call {
- return &mockAuthService_BUCPLogin_Call{Call: _e.mock.On("BUCPLogin", ctx, bodyIn, newUserFn)}
- }
- func (_c *mockAuthService_BUCPLogin_Call) Run(run func(ctx context.Context, bodyIn wire.SNAC_0x17_0x02_BUCPLoginRequest, newUserFn func(state.DisplayScreenName) (state.User, error))) *mockAuthService_BUCPLogin_Call {
- _c.Call.Run(func(args mock.Arguments) {
- run(args[0].(context.Context), args[1].(wire.SNAC_0x17_0x02_BUCPLoginRequest), args[2].(func(state.DisplayScreenName) (state.User, error)))
- })
- return _c
- }
- func (_c *mockAuthService_BUCPLogin_Call) Return(_a0 wire.SNACMessage, _a1 error) *mockAuthService_BUCPLogin_Call {
- _c.Call.Return(_a0, _a1)
- return _c
- }
- func (_c *mockAuthService_BUCPLogin_Call) RunAndReturn(run func(context.Context, wire.SNAC_0x17_0x02_BUCPLoginRequest, func(state.DisplayScreenName) (state.User, error)) (wire.SNACMessage, error)) *mockAuthService_BUCPLogin_Call {
- _c.Call.Return(run)
- return _c
- }
- // FLAPLogin provides a mock function with given fields: ctx, frame, newUserFn
- func (_m *mockAuthService) FLAPLogin(ctx context.Context, frame wire.FLAPSignonFrame, newUserFn func(state.DisplayScreenName) (state.User, error)) (wire.TLVRestBlock, error) {
- ret := _m.Called(ctx, frame, newUserFn)
- if len(ret) == 0 {
- panic("no return value specified for FLAPLogin")
- }
- var r0 wire.TLVRestBlock
- var r1 error
- if rf, ok := ret.Get(0).(func(context.Context, wire.FLAPSignonFrame, func(state.DisplayScreenName) (state.User, error)) (wire.TLVRestBlock, error)); ok {
- return rf(ctx, frame, newUserFn)
- }
- if rf, ok := ret.Get(0).(func(context.Context, wire.FLAPSignonFrame, func(state.DisplayScreenName) (state.User, error)) wire.TLVRestBlock); ok {
- r0 = rf(ctx, frame, newUserFn)
- } else {
- r0 = ret.Get(0).(wire.TLVRestBlock)
- }
- if rf, ok := ret.Get(1).(func(context.Context, wire.FLAPSignonFrame, func(state.DisplayScreenName) (state.User, error)) error); ok {
- r1 = rf(ctx, frame, newUserFn)
- } else {
- r1 = ret.Error(1)
- }
- return r0, r1
- }
- // mockAuthService_FLAPLogin_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FLAPLogin'
- type mockAuthService_FLAPLogin_Call struct {
- *mock.Call
- }
- // FLAPLogin is a helper method to define mock.On call
- // - ctx context.Context
- // - frame wire.FLAPSignonFrame
- // - newUserFn func(state.DisplayScreenName)(state.User , error)
- func (_e *mockAuthService_Expecter) FLAPLogin(ctx interface{}, frame interface{}, newUserFn interface{}) *mockAuthService_FLAPLogin_Call {
- return &mockAuthService_FLAPLogin_Call{Call: _e.mock.On("FLAPLogin", ctx, frame, newUserFn)}
- }
- func (_c *mockAuthService_FLAPLogin_Call) Run(run func(ctx context.Context, frame wire.FLAPSignonFrame, newUserFn func(state.DisplayScreenName) (state.User, error))) *mockAuthService_FLAPLogin_Call {
- _c.Call.Run(func(args mock.Arguments) {
- run(args[0].(context.Context), args[1].(wire.FLAPSignonFrame), args[2].(func(state.DisplayScreenName) (state.User, error)))
- })
- return _c
- }
- func (_c *mockAuthService_FLAPLogin_Call) Return(_a0 wire.TLVRestBlock, _a1 error) *mockAuthService_FLAPLogin_Call {
- _c.Call.Return(_a0, _a1)
- return _c
- }
- func (_c *mockAuthService_FLAPLogin_Call) RunAndReturn(run func(context.Context, wire.FLAPSignonFrame, func(state.DisplayScreenName) (state.User, error)) (wire.TLVRestBlock, error)) *mockAuthService_FLAPLogin_Call {
- _c.Call.Return(run)
- return _c
- }
- // RegisterBOSSession provides a mock function with given fields: ctx, authCookie
- func (_m *mockAuthService) RegisterBOSSession(ctx context.Context, authCookie []byte) (*state.Session, error) {
- ret := _m.Called(ctx, authCookie)
- if len(ret) == 0 {
- panic("no return value specified for RegisterBOSSession")
- }
- var r0 *state.Session
- var r1 error
- if rf, ok := ret.Get(0).(func(context.Context, []byte) (*state.Session, error)); ok {
- return rf(ctx, authCookie)
- }
- if rf, ok := ret.Get(0).(func(context.Context, []byte) *state.Session); ok {
- r0 = rf(ctx, authCookie)
- } else {
- if ret.Get(0) != nil {
- r0 = ret.Get(0).(*state.Session)
- }
- }
- if rf, ok := ret.Get(1).(func(context.Context, []byte) error); ok {
- r1 = rf(ctx, authCookie)
- } else {
- r1 = ret.Error(1)
- }
- return r0, r1
- }
- // mockAuthService_RegisterBOSSession_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RegisterBOSSession'
- type mockAuthService_RegisterBOSSession_Call struct {
- *mock.Call
- }
- // RegisterBOSSession is a helper method to define mock.On call
- // - ctx context.Context
- // - authCookie []byte
- func (_e *mockAuthService_Expecter) RegisterBOSSession(ctx interface{}, authCookie interface{}) *mockAuthService_RegisterBOSSession_Call {
- return &mockAuthService_RegisterBOSSession_Call{Call: _e.mock.On("RegisterBOSSession", ctx, authCookie)}
- }
- func (_c *mockAuthService_RegisterBOSSession_Call) Run(run func(ctx context.Context, authCookie []byte)) *mockAuthService_RegisterBOSSession_Call {
- _c.Call.Run(func(args mock.Arguments) {
- run(args[0].(context.Context), args[1].([]byte))
- })
- return _c
- }
- func (_c *mockAuthService_RegisterBOSSession_Call) Return(_a0 *state.Session, _a1 error) *mockAuthService_RegisterBOSSession_Call {
- _c.Call.Return(_a0, _a1)
- return _c
- }
- func (_c *mockAuthService_RegisterBOSSession_Call) RunAndReturn(run func(context.Context, []byte) (*state.Session, error)) *mockAuthService_RegisterBOSSession_Call {
- _c.Call.Return(run)
- return _c
- }
- // RegisterChatSession provides a mock function with given fields: ctx, authCookie
- func (_m *mockAuthService) RegisterChatSession(ctx context.Context, authCookie []byte) (*state.Session, error) {
- ret := _m.Called(ctx, authCookie)
- if len(ret) == 0 {
- panic("no return value specified for RegisterChatSession")
- }
- var r0 *state.Session
- var r1 error
- if rf, ok := ret.Get(0).(func(context.Context, []byte) (*state.Session, error)); ok {
- return rf(ctx, authCookie)
- }
- if rf, ok := ret.Get(0).(func(context.Context, []byte) *state.Session); ok {
- r0 = rf(ctx, authCookie)
- } else {
- if ret.Get(0) != nil {
- r0 = ret.Get(0).(*state.Session)
- }
- }
- if rf, ok := ret.Get(1).(func(context.Context, []byte) error); ok {
- r1 = rf(ctx, authCookie)
- } else {
- r1 = ret.Error(1)
- }
- return r0, r1
- }
- // mockAuthService_RegisterChatSession_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RegisterChatSession'
- type mockAuthService_RegisterChatSession_Call struct {
- *mock.Call
- }
- // RegisterChatSession is a helper method to define mock.On call
- // - ctx context.Context
- // - authCookie []byte
- func (_e *mockAuthService_Expecter) RegisterChatSession(ctx interface{}, authCookie interface{}) *mockAuthService_RegisterChatSession_Call {
- return &mockAuthService_RegisterChatSession_Call{Call: _e.mock.On("RegisterChatSession", ctx, authCookie)}
- }
- func (_c *mockAuthService_RegisterChatSession_Call) Run(run func(ctx context.Context, authCookie []byte)) *mockAuthService_RegisterChatSession_Call {
- _c.Call.Run(func(args mock.Arguments) {
- run(args[0].(context.Context), args[1].([]byte))
- })
- return _c
- }
- func (_c *mockAuthService_RegisterChatSession_Call) Return(_a0 *state.Session, _a1 error) *mockAuthService_RegisterChatSession_Call {
- _c.Call.Return(_a0, _a1)
- return _c
- }
- func (_c *mockAuthService_RegisterChatSession_Call) RunAndReturn(run func(context.Context, []byte) (*state.Session, error)) *mockAuthService_RegisterChatSession_Call {
- _c.Call.Return(run)
- return _c
- }
- // RetrieveBOSSession provides a mock function with given fields: ctx, authCookie
- func (_m *mockAuthService) RetrieveBOSSession(ctx context.Context, authCookie []byte) (*state.Session, error) {
- ret := _m.Called(ctx, authCookie)
- if len(ret) == 0 {
- panic("no return value specified for RetrieveBOSSession")
- }
- var r0 *state.Session
- var r1 error
- if rf, ok := ret.Get(0).(func(context.Context, []byte) (*state.Session, error)); ok {
- return rf(ctx, authCookie)
- }
- if rf, ok := ret.Get(0).(func(context.Context, []byte) *state.Session); ok {
- r0 = rf(ctx, authCookie)
- } else {
- if ret.Get(0) != nil {
- r0 = ret.Get(0).(*state.Session)
- }
- }
- if rf, ok := ret.Get(1).(func(context.Context, []byte) error); ok {
- r1 = rf(ctx, authCookie)
- } else {
- r1 = ret.Error(1)
- }
- return r0, r1
- }
- // mockAuthService_RetrieveBOSSession_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RetrieveBOSSession'
- type mockAuthService_RetrieveBOSSession_Call struct {
- *mock.Call
- }
- // RetrieveBOSSession is a helper method to define mock.On call
- // - ctx context.Context
- // - authCookie []byte
- func (_e *mockAuthService_Expecter) RetrieveBOSSession(ctx interface{}, authCookie interface{}) *mockAuthService_RetrieveBOSSession_Call {
- return &mockAuthService_RetrieveBOSSession_Call{Call: _e.mock.On("RetrieveBOSSession", ctx, authCookie)}
- }
- func (_c *mockAuthService_RetrieveBOSSession_Call) Run(run func(ctx context.Context, authCookie []byte)) *mockAuthService_RetrieveBOSSession_Call {
- _c.Call.Run(func(args mock.Arguments) {
- run(args[0].(context.Context), args[1].([]byte))
- })
- return _c
- }
- func (_c *mockAuthService_RetrieveBOSSession_Call) Return(_a0 *state.Session, _a1 error) *mockAuthService_RetrieveBOSSession_Call {
- _c.Call.Return(_a0, _a1)
- return _c
- }
- func (_c *mockAuthService_RetrieveBOSSession_Call) RunAndReturn(run func(context.Context, []byte) (*state.Session, error)) *mockAuthService_RetrieveBOSSession_Call {
- _c.Call.Return(run)
- return _c
- }
- // Signout provides a mock function with given fields: ctx, sess
- func (_m *mockAuthService) Signout(ctx context.Context, sess *state.Session) {
- _m.Called(ctx, sess)
- }
- // mockAuthService_Signout_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Signout'
- type mockAuthService_Signout_Call struct {
- *mock.Call
- }
- // Signout is a helper method to define mock.On call
- // - ctx context.Context
- // - sess *state.Session
- func (_e *mockAuthService_Expecter) Signout(ctx interface{}, sess interface{}) *mockAuthService_Signout_Call {
- return &mockAuthService_Signout_Call{Call: _e.mock.On("Signout", ctx, sess)}
- }
- func (_c *mockAuthService_Signout_Call) Run(run func(ctx context.Context, sess *state.Session)) *mockAuthService_Signout_Call {
- _c.Call.Run(func(args mock.Arguments) {
- run(args[0].(context.Context), args[1].(*state.Session))
- })
- return _c
- }
- func (_c *mockAuthService_Signout_Call) Return() *mockAuthService_Signout_Call {
- _c.Call.Return()
- return _c
- }
- func (_c *mockAuthService_Signout_Call) RunAndReturn(run func(context.Context, *state.Session)) *mockAuthService_Signout_Call {
- _c.Run(run)
- return _c
- }
- // SignoutChat provides a mock function with given fields: ctx, sess
- func (_m *mockAuthService) SignoutChat(ctx context.Context, sess *state.Session) {
- _m.Called(ctx, sess)
- }
- // mockAuthService_SignoutChat_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SignoutChat'
- type mockAuthService_SignoutChat_Call struct {
- *mock.Call
- }
- // SignoutChat is a helper method to define mock.On call
- // - ctx context.Context
- // - sess *state.Session
- func (_e *mockAuthService_Expecter) SignoutChat(ctx interface{}, sess interface{}) *mockAuthService_SignoutChat_Call {
- return &mockAuthService_SignoutChat_Call{Call: _e.mock.On("SignoutChat", ctx, sess)}
- }
- func (_c *mockAuthService_SignoutChat_Call) Run(run func(ctx context.Context, sess *state.Session)) *mockAuthService_SignoutChat_Call {
- _c.Call.Run(func(args mock.Arguments) {
- run(args[0].(context.Context), args[1].(*state.Session))
- })
- return _c
- }
- func (_c *mockAuthService_SignoutChat_Call) Return() *mockAuthService_SignoutChat_Call {
- _c.Call.Return()
- return _c
- }
- func (_c *mockAuthService_SignoutChat_Call) RunAndReturn(run func(context.Context, *state.Session)) *mockAuthService_SignoutChat_Call {
- _c.Run(run)
- return _c
- }
- // newMockAuthService creates a new instance of mockAuthService. 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 newMockAuthService(t interface {
- mock.TestingT
- Cleanup(func())
- }) *mockAuthService {
- mock := &mockAuthService{}
- mock.Mock.Test(t)
- t.Cleanup(func() { mock.AssertExpectations(t) })
- return mock
- }
|