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_chat_room_registry_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"
)

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

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

	return mock
}

// mockChatRoomRegistry is an autogenerated mock type for the ChatRoomRegistry type
type mockChatRoomRegistry struct {
	mock.Mock
}

type mockChatRoomRegistry_Expecter struct {
	mock *mock.Mock
}

func (_m *mockChatRoomRegistry) EXPECT() *mockChatRoomRegistry_Expecter {
	return &mockChatRoomRegistry_Expecter{mock: &_m.Mock}
}

// ChatRoomByCookie provides a mock function for the type mockChatRoomRegistry
func (_mock *mockChatRoomRegistry) ChatRoomByCookie(ctx context.Context, chatCookie string) (state.ChatRoom, error) {
	ret := _mock.Called(ctx, chatCookie)

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

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

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

// ChatRoomByCookie is a helper method to define mock.On call
//   - ctx context.Context
//   - chatCookie string
func (_e *mockChatRoomRegistry_Expecter) ChatRoomByCookie(ctx interface{}, chatCookie interface{}) *mockChatRoomRegistry_ChatRoomByCookie_Call {
	return &mockChatRoomRegistry_ChatRoomByCookie_Call{Call: _e.mock.On("ChatRoomByCookie", ctx, chatCookie)}
}

func (_c *mockChatRoomRegistry_ChatRoomByCookie_Call) Run(run func(ctx context.Context, chatCookie string)) *mockChatRoomRegistry_ChatRoomByCookie_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 *mockChatRoomRegistry_ChatRoomByCookie_Call) Return(chatRoom state.ChatRoom, err error) *mockChatRoomRegistry_ChatRoomByCookie_Call {
	_c.Call.Return(chatRoom, err)
	return _c
}

func (_c *mockChatRoomRegistry_ChatRoomByCookie_Call) RunAndReturn(run func(ctx context.Context, chatCookie string) (state.ChatRoom, error)) *mockChatRoomRegistry_ChatRoomByCookie_Call {
	_c.Call.Return(run)
	return _c
}

// ChatRoomByName provides a mock function for the type mockChatRoomRegistry
func (_mock *mockChatRoomRegistry) ChatRoomByName(ctx context.Context, exchange uint16, name string) (state.ChatRoom, error) {
	ret := _mock.Called(ctx, exchange, name)

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

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

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

// ChatRoomByName is a helper method to define mock.On call
//   - ctx context.Context
//   - exchange uint16
//   - name string
func (_e *mockChatRoomRegistry_Expecter) ChatRoomByName(ctx interface{}, exchange interface{}, name interface{}) *mockChatRoomRegistry_ChatRoomByName_Call {
	return &mockChatRoomRegistry_ChatRoomByName_Call{Call: _e.mock.On("ChatRoomByName", ctx, exchange, name)}
}

func (_c *mockChatRoomRegistry_ChatRoomByName_Call) Run(run func(ctx context.Context, exchange uint16, name string)) *mockChatRoomRegistry_ChatRoomByName_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 *mockChatRoomRegistry_ChatRoomByName_Call) Return(chatRoom state.ChatRoom, err error) *mockChatRoomRegistry_ChatRoomByName_Call {
	_c.Call.Return(chatRoom, err)
	return _c
}

func (_c *mockChatRoomRegistry_ChatRoomByName_Call) RunAndReturn(run func(ctx context.Context, exchange uint16, name string) (state.ChatRoom, error)) *mockChatRoomRegistry_ChatRoomByName_Call {
	_c.Call.Return(run)
	return _c
}

// CreateChatRoom provides a mock function for the type mockChatRoomRegistry
func (_mock *mockChatRoomRegistry) CreateChatRoom(ctx context.Context, chatRoom *state.ChatRoom) error {
	ret := _mock.Called(ctx, chatRoom)

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

	var r0 error
	if returnFunc, ok := ret.Get(0).(func(context.Context, *state.ChatRoom) error); ok {
		r0 = returnFunc(ctx, chatRoom)
	} else {
		r0 = ret.Error(0)
	}
	return r0
}

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

// CreateChatRoom is a helper method to define mock.On call
//   - ctx context.Context
//   - chatRoom *state.ChatRoom
func (_e *mockChatRoomRegistry_Expecter) CreateChatRoom(ctx interface{}, chatRoom interface{}) *mockChatRoomRegistry_CreateChatRoom_Call {
	return &mockChatRoomRegistry_CreateChatRoom_Call{Call: _e.mock.On("CreateChatRoom", ctx, chatRoom)}
}

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

func (_c *mockChatRoomRegistry_CreateChatRoom_Call) Return(err error) *mockChatRoomRegistry_CreateChatRoom_Call {
	_c.Call.Return(err)
	return _c
}

func (_c *mockChatRoomRegistry_CreateChatRoom_Call) RunAndReturn(run func(ctx context.Context, chatRoom *state.ChatRoom) error) *mockChatRoomRegistry_CreateChatRoom_Call {
	_c.Call.Return(run)
	return _c
}

Youez - 2016 - github.com/yon3zu
LinuXploit