403Webshell
Server IP : 157.230.181.24  /  Your IP : 216.73.217.11
Web Server : Apache/2.4.58 (Ubuntu)
System : Linux conductive 6.8.0-117-generic #117-Ubuntu SMP PREEMPT_DYNAMIC Tue May 5 19:26:24 UTC 2026 x86_64
User :  ( 1000)
PHP Version : 8.3.31
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /var/www/vhosts/ceagon/open-oscar-server/foodgroup/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/vhosts/ceagon/open-oscar-server/foodgroup/mock_icq_user_finder_test.go
// Code generated by mockery; DO NOT EDIT.
// github.com/vektra/mockery
// template: testify

package foodgroup

import (
	"context"

	"github.com/mk6i/open-oscar-server/state"
	mock "github.com/stretchr/testify/mock"
)

// newMockICQUserFinder creates a new instance of mockICQUserFinder. 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 newMockICQUserFinder(t interface {
	mock.TestingT
	Cleanup(func())
}) *mockICQUserFinder {
	mock := &mockICQUserFinder{}
	mock.Mock.Test(t)

	t.Cleanup(func() { mock.AssertExpectations(t) })

	return mock
}

// mockICQUserFinder is an autogenerated mock type for the ICQUserFinder type
type mockICQUserFinder struct {
	mock.Mock
}

type mockICQUserFinder_Expecter struct {
	mock *mock.Mock
}

func (_m *mockICQUserFinder) EXPECT() *mockICQUserFinder_Expecter {
	return &mockICQUserFinder_Expecter{mock: &_m.Mock}
}

// FindByICQEmail provides a mock function for the type mockICQUserFinder
func (_mock *mockICQUserFinder) FindByICQEmail(ctx context.Context, email string) (state.User, error) {
	ret := _mock.Called(ctx, email)

	if len(ret) == 0 {
		panic("no return value specified for FindByICQEmail")
	}

	var r0 state.User
	var r1 error
	if returnFunc, ok := ret.Get(0).(func(context.Context, string) (state.User, error)); ok {
		return returnFunc(ctx, email)
	}
	if returnFunc, ok := ret.Get(0).(func(context.Context, string) state.User); ok {
		r0 = returnFunc(ctx, email)
	} else {
		r0 = ret.Get(0).(state.User)
	}
	if returnFunc, ok := ret.Get(1).(func(context.Context, string) error); ok {
		r1 = returnFunc(ctx, email)
	} else {
		r1 = ret.Error(1)
	}
	return r0, r1
}

// mockICQUserFinder_FindByICQEmail_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FindByICQEmail'
type mockICQUserFinder_FindByICQEmail_Call struct {
	*mock.Call
}

// FindByICQEmail is a helper method to define mock.On call
//   - ctx context.Context
//   - email string
func (_e *mockICQUserFinder_Expecter) FindByICQEmail(ctx interface{}, email interface{}) *mockICQUserFinder_FindByICQEmail_Call {
	return &mockICQUserFinder_FindByICQEmail_Call{Call: _e.mock.On("FindByICQEmail", ctx, email)}
}

func (_c *mockICQUserFinder_FindByICQEmail_Call) Run(run func(ctx context.Context, email string)) *mockICQUserFinder_FindByICQEmail_Call {
	_c.Call.Run(func(args mock.Arguments) {
		var arg0 context.Context
		if args[0] != nil {
			arg0 = args[0].(context.Context)
		}
		var arg1 string
		if args[1] != nil {
			arg1 = args[1].(string)
		}
		run(
			arg0,
			arg1,
		)
	})
	return _c
}

func (_c *mockICQUserFinder_FindByICQEmail_Call) Return(user state.User, err error) *mockICQUserFinder_FindByICQEmail_Call {
	_c.Call.Return(user, err)
	return _c
}

func (_c *mockICQUserFinder_FindByICQEmail_Call) RunAndReturn(run func(ctx context.Context, email string) (state.User, error)) *mockICQUserFinder_FindByICQEmail_Call {
	_c.Call.Return(run)
	return _c
}

// FindByICQInterests provides a mock function for the type mockICQUserFinder
func (_mock *mockICQUserFinder) FindByICQInterests(ctx context.Context, code uint16, keywords []string) ([]state.User, error) {
	ret := _mock.Called(ctx, code, keywords)

	if len(ret) == 0 {
		panic("no return value specified for FindByICQInterests")
	}

	var r0 []state.User
	var r1 error
	if returnFunc, ok := ret.Get(0).(func(context.Context, uint16, []string) ([]state.User, error)); ok {
		return returnFunc(ctx, code, keywords)
	}
	if returnFunc, ok := ret.Get(0).(func(context.Context, uint16, []string) []state.User); ok {
		r0 = returnFunc(ctx, code, keywords)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]state.User)
		}
	}
	if returnFunc, ok := ret.Get(1).(func(context.Context, uint16, []string) error); ok {
		r1 = returnFunc(ctx, code, keywords)
	} else {
		r1 = ret.Error(1)
	}
	return r0, r1
}

// mockICQUserFinder_FindByICQInterests_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FindByICQInterests'
type mockICQUserFinder_FindByICQInterests_Call struct {
	*mock.Call
}

// FindByICQInterests is a helper method to define mock.On call
//   - ctx context.Context
//   - code uint16
//   - keywords []string
func (_e *mockICQUserFinder_Expecter) FindByICQInterests(ctx interface{}, code interface{}, keywords interface{}) *mockICQUserFinder_FindByICQInterests_Call {
	return &mockICQUserFinder_FindByICQInterests_Call{Call: _e.mock.On("FindByICQInterests", ctx, code, keywords)}
}

func (_c *mockICQUserFinder_FindByICQInterests_Call) Run(run func(ctx context.Context, code uint16, keywords []string)) *mockICQUserFinder_FindByICQInterests_Call {
	_c.Call.Run(func(args mock.Arguments) {
		var arg0 context.Context
		if args[0] != nil {
			arg0 = args[0].(context.Context)
		}
		var arg1 uint16
		if args[1] != nil {
			arg1 = args[1].(uint16)
		}
		var arg2 []string
		if args[2] != nil {
			arg2 = args[2].([]string)
		}
		run(
			arg0,
			arg1,
			arg2,
		)
	})
	return _c
}

func (_c *mockICQUserFinder_FindByICQInterests_Call) Return(users []state.User, err error) *mockICQUserFinder_FindByICQInterests_Call {
	_c.Call.Return(users, err)
	return _c
}

func (_c *mockICQUserFinder_FindByICQInterests_Call) RunAndReturn(run func(ctx context.Context, code uint16, keywords []string) ([]state.User, error)) *mockICQUserFinder_FindByICQInterests_Call {
	_c.Call.Return(run)
	return _c
}

// FindByICQKeyword provides a mock function for the type mockICQUserFinder
func (_mock *mockICQUserFinder) FindByICQKeyword(ctx context.Context, keyword string) ([]state.User, error) {
	ret := _mock.Called(ctx, keyword)

	if len(ret) == 0 {
		panic("no return value specified for FindByICQKeyword")
	}

	var r0 []state.User
	var r1 error
	if returnFunc, ok := ret.Get(0).(func(context.Context, string) ([]state.User, error)); ok {
		return returnFunc(ctx, keyword)
	}
	if returnFunc, ok := ret.Get(0).(func(context.Context, string) []state.User); ok {
		r0 = returnFunc(ctx, keyword)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]state.User)
		}
	}
	if returnFunc, ok := ret.Get(1).(func(context.Context, string) error); ok {
		r1 = returnFunc(ctx, keyword)
	} else {
		r1 = ret.Error(1)
	}
	return r0, r1
}

// mockICQUserFinder_FindByICQKeyword_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FindByICQKeyword'
type mockICQUserFinder_FindByICQKeyword_Call struct {
	*mock.Call
}

// FindByICQKeyword is a helper method to define mock.On call
//   - ctx context.Context
//   - keyword string
func (_e *mockICQUserFinder_Expecter) FindByICQKeyword(ctx interface{}, keyword interface{}) *mockICQUserFinder_FindByICQKeyword_Call {
	return &mockICQUserFinder_FindByICQKeyword_Call{Call: _e.mock.On("FindByICQKeyword", ctx, keyword)}
}

func (_c *mockICQUserFinder_FindByICQKeyword_Call) Run(run func(ctx context.Context, keyword string)) *mockICQUserFinder_FindByICQKeyword_Call {
	_c.Call.Run(func(args mock.Arguments) {
		var arg0 context.Context
		if args[0] != nil {
			arg0 = args[0].(context.Context)
		}
		var arg1 string
		if args[1] != nil {
			arg1 = args[1].(string)
		}
		run(
			arg0,
			arg1,
		)
	})
	return _c
}

func (_c *mockICQUserFinder_FindByICQKeyword_Call) Return(users []state.User, err error) *mockICQUserFinder_FindByICQKeyword_Call {
	_c.Call.Return(users, err)
	return _c
}

func (_c *mockICQUserFinder_FindByICQKeyword_Call) RunAndReturn(run func(ctx context.Context, keyword string) ([]state.User, error)) *mockICQUserFinder_FindByICQKeyword_Call {
	_c.Call.Return(run)
	return _c
}

// FindByICQName provides a mock function for the type mockICQUserFinder
func (_mock *mockICQUserFinder) FindByICQName(ctx context.Context, firstName string, lastName string, nickName string) ([]state.User, error) {
	ret := _mock.Called(ctx, firstName, lastName, nickName)

	if len(ret) == 0 {
		panic("no return value specified for FindByICQName")
	}

	var r0 []state.User
	var r1 error
	if returnFunc, ok := ret.Get(0).(func(context.Context, string, string, string) ([]state.User, error)); ok {
		return returnFunc(ctx, firstName, lastName, nickName)
	}
	if returnFunc, ok := ret.Get(0).(func(context.Context, string, string, string) []state.User); ok {
		r0 = returnFunc(ctx, firstName, lastName, nickName)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]state.User)
		}
	}
	if returnFunc, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok {
		r1 = returnFunc(ctx, firstName, lastName, nickName)
	} else {
		r1 = ret.Error(1)
	}
	return r0, r1
}

// mockICQUserFinder_FindByICQName_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FindByICQName'
type mockICQUserFinder_FindByICQName_Call struct {
	*mock.Call
}

// FindByICQName is a helper method to define mock.On call
//   - ctx context.Context
//   - firstName string
//   - lastName string
//   - nickName string
func (_e *mockICQUserFinder_Expecter) FindByICQName(ctx interface{}, firstName interface{}, lastName interface{}, nickName interface{}) *mockICQUserFinder_FindByICQName_Call {
	return &mockICQUserFinder_FindByICQName_Call{Call: _e.mock.On("FindByICQName", ctx, firstName, lastName, nickName)}
}

func (_c *mockICQUserFinder_FindByICQName_Call) Run(run func(ctx context.Context, firstName string, lastName string, nickName string)) *mockICQUserFinder_FindByICQName_Call {
	_c.Call.Run(func(args mock.Arguments) {
		var arg0 context.Context
		if args[0] != nil {
			arg0 = args[0].(context.Context)
		}
		var arg1 string
		if args[1] != nil {
			arg1 = args[1].(string)
		}
		var arg2 string
		if args[2] != nil {
			arg2 = args[2].(string)
		}
		var arg3 string
		if args[3] != nil {
			arg3 = args[3].(string)
		}
		run(
			arg0,
			arg1,
			arg2,
			arg3,
		)
	})
	return _c
}

func (_c *mockICQUserFinder_FindByICQName_Call) Return(users []state.User, err error) *mockICQUserFinder_FindByICQName_Call {
	_c.Call.Return(users, err)
	return _c
}

func (_c *mockICQUserFinder_FindByICQName_Call) RunAndReturn(run func(ctx context.Context, firstName string, lastName string, nickName string) ([]state.User, error)) *mockICQUserFinder_FindByICQName_Call {
	_c.Call.Return(run)
	return _c
}

// FindByUIN provides a mock function for the type mockICQUserFinder
func (_mock *mockICQUserFinder) FindByUIN(ctx context.Context, UIN uint32) (state.User, error) {
	ret := _mock.Called(ctx, UIN)

	if len(ret) == 0 {
		panic("no return value specified for FindByUIN")
	}

	var r0 state.User
	var r1 error
	if returnFunc, ok := ret.Get(0).(func(context.Context, uint32) (state.User, error)); ok {
		return returnFunc(ctx, UIN)
	}
	if returnFunc, ok := ret.Get(0).(func(context.Context, uint32) state.User); ok {
		r0 = returnFunc(ctx, UIN)
	} else {
		r0 = ret.Get(0).(state.User)
	}
	if returnFunc, ok := ret.Get(1).(func(context.Context, uint32) error); ok {
		r1 = returnFunc(ctx, UIN)
	} else {
		r1 = ret.Error(1)
	}
	return r0, r1
}

// mockICQUserFinder_FindByUIN_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FindByUIN'
type mockICQUserFinder_FindByUIN_Call struct {
	*mock.Call
}

// FindByUIN is a helper method to define mock.On call
//   - ctx context.Context
//   - UIN uint32
func (_e *mockICQUserFinder_Expecter) FindByUIN(ctx interface{}, UIN interface{}) *mockICQUserFinder_FindByUIN_Call {
	return &mockICQUserFinder_FindByUIN_Call{Call: _e.mock.On("FindByUIN", ctx, UIN)}
}

func (_c *mockICQUserFinder_FindByUIN_Call) Run(run func(ctx context.Context, UIN uint32)) *mockICQUserFinder_FindByUIN_Call {
	_c.Call.Run(func(args mock.Arguments) {
		var arg0 context.Context
		if args[0] != nil {
			arg0 = args[0].(context.Context)
		}
		var arg1 uint32
		if args[1] != nil {
			arg1 = args[1].(uint32)
		}
		run(
			arg0,
			arg1,
		)
	})
	return _c
}

func (_c *mockICQUserFinder_FindByUIN_Call) Return(user state.User, err error) *mockICQUserFinder_FindByUIN_Call {
	_c.Call.Return(user, err)
	return _c
}

func (_c *mockICQUserFinder_FindByUIN_Call) RunAndReturn(run func(ctx context.Context, UIN uint32) (state.User, error)) *mockICQUserFinder_FindByUIN_Call {
	_c.Call.Return(run)
	return _c
}

// SearchICQUsers provides a mock function for the type mockICQUserFinder
func (_mock *mockICQUserFinder) SearchICQUsers(ctx context.Context, c state.ICQUserSearchCriteria) ([]state.User, error) {
	ret := _mock.Called(ctx, c)

	if len(ret) == 0 {
		panic("no return value specified for SearchICQUsers")
	}

	var r0 []state.User
	var r1 error
	if returnFunc, ok := ret.Get(0).(func(context.Context, state.ICQUserSearchCriteria) ([]state.User, error)); ok {
		return returnFunc(ctx, c)
	}
	if returnFunc, ok := ret.Get(0).(func(context.Context, state.ICQUserSearchCriteria) []state.User); ok {
		r0 = returnFunc(ctx, c)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]state.User)
		}
	}
	if returnFunc, ok := ret.Get(1).(func(context.Context, state.ICQUserSearchCriteria) error); ok {
		r1 = returnFunc(ctx, c)
	} else {
		r1 = ret.Error(1)
	}
	return r0, r1
}

// mockICQUserFinder_SearchICQUsers_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SearchICQUsers'
type mockICQUserFinder_SearchICQUsers_Call struct {
	*mock.Call
}

// SearchICQUsers is a helper method to define mock.On call
//   - ctx context.Context
//   - c state.ICQUserSearchCriteria
func (_e *mockICQUserFinder_Expecter) SearchICQUsers(ctx interface{}, c interface{}) *mockICQUserFinder_SearchICQUsers_Call {
	return &mockICQUserFinder_SearchICQUsers_Call{Call: _e.mock.On("SearchICQUsers", ctx, c)}
}

func (_c *mockICQUserFinder_SearchICQUsers_Call) Run(run func(ctx context.Context, c state.ICQUserSearchCriteria)) *mockICQUserFinder_SearchICQUsers_Call {
	_c.Call.Run(func(args mock.Arguments) {
		var arg0 context.Context
		if args[0] != nil {
			arg0 = args[0].(context.Context)
		}
		var arg1 state.ICQUserSearchCriteria
		if args[1] != nil {
			arg1 = args[1].(state.ICQUserSearchCriteria)
		}
		run(
			arg0,
			arg1,
		)
	})
	return _c
}

func (_c *mockICQUserFinder_SearchICQUsers_Call) Return(users []state.User, err error) *mockICQUserFinder_SearchICQUsers_Call {
	_c.Call.Return(users, err)
	return _c
}

func (_c *mockICQUserFinder_SearchICQUsers_Call) RunAndReturn(run func(ctx context.Context, c state.ICQUserSearchCriteria) ([]state.User, error)) *mockICQUserFinder_SearchICQUsers_Call {
	_c.Call.Return(run)
	return _c
}

Youez - 2016 - github.com/yon3zu
LinuXploit