// Code generated by mockery. DO NOT EDIT.

package mock_nameservice

import (
	context "context"

	app "github.com/anyproto/any-sync/app"

	mock "github.com/stretchr/testify/mock"

	pb "github.com/anyproto/anytype-heart/pb"
)

// MockService is an autogenerated mock type for the Service type
type MockService struct {
	mock.Mock
}

type MockService_Expecter struct {
	mock *mock.Mock
}

func (_m *MockService) EXPECT() *MockService_Expecter {
	return &MockService_Expecter{mock: &_m.Mock}
}

// Init provides a mock function with given fields: a
func (_m *MockService) Init(a *app.App) error {
	ret := _m.Called(a)

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

	var r0 error
	if rf, ok := ret.Get(0).(func(*app.App) error); ok {
		r0 = rf(a)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

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

// Init is a helper method to define mock.On call
//   - a *app.App
func (_e *MockService_Expecter) Init(a interface{}) *MockService_Init_Call {
	return &MockService_Init_Call{Call: _e.mock.On("Init", a)}
}

func (_c *MockService_Init_Call) Run(run func(a *app.App)) *MockService_Init_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(*app.App))
	})
	return _c
}

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

func (_c *MockService_Init_Call) RunAndReturn(run func(*app.App) error) *MockService_Init_Call {
	_c.Call.Return(run)
	return _c
}

// Name provides a mock function with given fields:
func (_m *MockService) Name() string {
	ret := _m.Called()

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

	var r0 string
	if rf, ok := ret.Get(0).(func() string); ok {
		r0 = rf()
	} else {
		r0 = ret.Get(0).(string)
	}

	return r0
}

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

// Name is a helper method to define mock.On call
func (_e *MockService_Expecter) Name() *MockService_Name_Call {
	return &MockService_Name_Call{Call: _e.mock.On("Name")}
}

func (_c *MockService_Name_Call) Run(run func()) *MockService_Name_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run()
	})
	return _c
}

func (_c *MockService_Name_Call) Return(name string) *MockService_Name_Call {
	_c.Call.Return(name)
	return _c
}

func (_c *MockService_Name_Call) RunAndReturn(run func() string) *MockService_Name_Call {
	_c.Call.Return(run)
	return _c
}

// NameServiceResolveAnyId provides a mock function with given fields: ctx, req
func (_m *MockService) NameServiceResolveAnyId(ctx context.Context, req *pb.RpcNameServiceResolveAnyIdRequest) (*pb.RpcNameServiceResolveAnyIdResponse, error) {
	ret := _m.Called(ctx, req)

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

	var r0 *pb.RpcNameServiceResolveAnyIdResponse
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, *pb.RpcNameServiceResolveAnyIdRequest) (*pb.RpcNameServiceResolveAnyIdResponse, error)); ok {
		return rf(ctx, req)
	}
	if rf, ok := ret.Get(0).(func(context.Context, *pb.RpcNameServiceResolveAnyIdRequest) *pb.RpcNameServiceResolveAnyIdResponse); ok {
		r0 = rf(ctx, req)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*pb.RpcNameServiceResolveAnyIdResponse)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, *pb.RpcNameServiceResolveAnyIdRequest) error); ok {
		r1 = rf(ctx, req)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// NameServiceResolveAnyId is a helper method to define mock.On call
//   - ctx context.Context
//   - req *pb.RpcNameServiceResolveAnyIdRequest
func (_e *MockService_Expecter) NameServiceResolveAnyId(ctx interface{}, req interface{}) *MockService_NameServiceResolveAnyId_Call {
	return &MockService_NameServiceResolveAnyId_Call{Call: _e.mock.On("NameServiceResolveAnyId", ctx, req)}
}

func (_c *MockService_NameServiceResolveAnyId_Call) Run(run func(ctx context.Context, req *pb.RpcNameServiceResolveAnyIdRequest)) *MockService_NameServiceResolveAnyId_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(context.Context), args[1].(*pb.RpcNameServiceResolveAnyIdRequest))
	})
	return _c
}

func (_c *MockService_NameServiceResolveAnyId_Call) Return(_a0 *pb.RpcNameServiceResolveAnyIdResponse, _a1 error) *MockService_NameServiceResolveAnyId_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *MockService_NameServiceResolveAnyId_Call) RunAndReturn(run func(context.Context, *pb.RpcNameServiceResolveAnyIdRequest) (*pb.RpcNameServiceResolveAnyIdResponse, error)) *MockService_NameServiceResolveAnyId_Call {
	_c.Call.Return(run)
	return _c
}

// NameServiceResolveName provides a mock function with given fields: ctx, req
func (_m *MockService) NameServiceResolveName(ctx context.Context, req *pb.RpcNameServiceResolveNameRequest) (*pb.RpcNameServiceResolveNameResponse, error) {
	ret := _m.Called(ctx, req)

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

	var r0 *pb.RpcNameServiceResolveNameResponse
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, *pb.RpcNameServiceResolveNameRequest) (*pb.RpcNameServiceResolveNameResponse, error)); ok {
		return rf(ctx, req)
	}
	if rf, ok := ret.Get(0).(func(context.Context, *pb.RpcNameServiceResolveNameRequest) *pb.RpcNameServiceResolveNameResponse); ok {
		r0 = rf(ctx, req)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*pb.RpcNameServiceResolveNameResponse)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, *pb.RpcNameServiceResolveNameRequest) error); ok {
		r1 = rf(ctx, req)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// NameServiceResolveName is a helper method to define mock.On call
//   - ctx context.Context
//   - req *pb.RpcNameServiceResolveNameRequest
func (_e *MockService_Expecter) NameServiceResolveName(ctx interface{}, req interface{}) *MockService_NameServiceResolveName_Call {
	return &MockService_NameServiceResolveName_Call{Call: _e.mock.On("NameServiceResolveName", ctx, req)}
}

func (_c *MockService_NameServiceResolveName_Call) Run(run func(ctx context.Context, req *pb.RpcNameServiceResolveNameRequest)) *MockService_NameServiceResolveName_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(context.Context), args[1].(*pb.RpcNameServiceResolveNameRequest))
	})
	return _c
}

func (_c *MockService_NameServiceResolveName_Call) Return(_a0 *pb.RpcNameServiceResolveNameResponse, _a1 error) *MockService_NameServiceResolveName_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *MockService_NameServiceResolveName_Call) RunAndReturn(run func(context.Context, *pb.RpcNameServiceResolveNameRequest) (*pb.RpcNameServiceResolveNameResponse, error)) *MockService_NameServiceResolveName_Call {
	_c.Call.Return(run)
	return _c
}

// NameServiceUserAccountGet provides a mock function with given fields: ctx, req
func (_m *MockService) NameServiceUserAccountGet(ctx context.Context, req *pb.RpcNameServiceUserAccountGetRequest) (*pb.RpcNameServiceUserAccountGetResponse, error) {
	ret := _m.Called(ctx, req)

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

	var r0 *pb.RpcNameServiceUserAccountGetResponse
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, *pb.RpcNameServiceUserAccountGetRequest) (*pb.RpcNameServiceUserAccountGetResponse, error)); ok {
		return rf(ctx, req)
	}
	if rf, ok := ret.Get(0).(func(context.Context, *pb.RpcNameServiceUserAccountGetRequest) *pb.RpcNameServiceUserAccountGetResponse); ok {
		r0 = rf(ctx, req)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*pb.RpcNameServiceUserAccountGetResponse)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, *pb.RpcNameServiceUserAccountGetRequest) error); ok {
		r1 = rf(ctx, req)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// NameServiceUserAccountGet is a helper method to define mock.On call
//   - ctx context.Context
//   - req *pb.RpcNameServiceUserAccountGetRequest
func (_e *MockService_Expecter) NameServiceUserAccountGet(ctx interface{}, req interface{}) *MockService_NameServiceUserAccountGet_Call {
	return &MockService_NameServiceUserAccountGet_Call{Call: _e.mock.On("NameServiceUserAccountGet", ctx, req)}
}

func (_c *MockService_NameServiceUserAccountGet_Call) Run(run func(ctx context.Context, req *pb.RpcNameServiceUserAccountGetRequest)) *MockService_NameServiceUserAccountGet_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(context.Context), args[1].(*pb.RpcNameServiceUserAccountGetRequest))
	})
	return _c
}

func (_c *MockService_NameServiceUserAccountGet_Call) Return(_a0 *pb.RpcNameServiceUserAccountGetResponse, _a1 error) *MockService_NameServiceUserAccountGet_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *MockService_NameServiceUserAccountGet_Call) RunAndReturn(run func(context.Context, *pb.RpcNameServiceUserAccountGetRequest) (*pb.RpcNameServiceUserAccountGetResponse, error)) *MockService_NameServiceUserAccountGet_Call {
	_c.Call.Return(run)
	return _c
}

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

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

	return mock
}
