// Code generated by moq; DO NOT EDIT.
// github.com/matryer/moq

package mock

import (
	"github.com/axelarnetwork/axelar-core/x/ante/types"
	permission "github.com/axelarnetwork/axelar-core/x/permission/exported"
	rewardtypes "github.com/axelarnetwork/axelar-core/x/reward/types"
	sdk "github.com/cosmos/cosmos-sdk/types"
	stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types"
	"sync"
)

// Ensure, that PermissionMock does implement types.Permission.
// If this is not the case, regenerate this file with moq.
var _ types.Permission = &PermissionMock{}

// PermissionMock is a mock implementation of types.Permission.
//
//	func TestSomethingThatUsesPermission(t *testing.T) {
//
//		// make and configure a mocked types.Permission
//		mockedPermission := &PermissionMock{
//			GetRoleFunc: func(ctx sdk.Context, address sdk.AccAddress) permission.Role {
//				panic("mock out the GetRole method")
//			},
//		}
//
//		// use mockedPermission in code that requires types.Permission
//		// and then make assertions.
//
//	}
type PermissionMock struct {
	// GetRoleFunc mocks the GetRole method.
	GetRoleFunc func(ctx sdk.Context, address sdk.AccAddress) permission.Role

	// calls tracks calls to the methods.
	calls struct {
		// GetRole holds details about calls to the GetRole method.
		GetRole []struct {
			// Ctx is the ctx argument value.
			Ctx sdk.Context
			// Address is the address argument value.
			Address sdk.AccAddress
		}
	}
	lockGetRole sync.RWMutex
}

// GetRole calls GetRoleFunc.
func (mock *PermissionMock) GetRole(ctx sdk.Context, address sdk.AccAddress) permission.Role {
	if mock.GetRoleFunc == nil {
		panic("PermissionMock.GetRoleFunc: method is nil but Permission.GetRole was just called")
	}
	callInfo := struct {
		Ctx     sdk.Context
		Address sdk.AccAddress
	}{
		Ctx:     ctx,
		Address: address,
	}
	mock.lockGetRole.Lock()
	mock.calls.GetRole = append(mock.calls.GetRole, callInfo)
	mock.lockGetRole.Unlock()
	return mock.GetRoleFunc(ctx, address)
}

// GetRoleCalls gets all the calls that were made to GetRole.
// Check the length with:
//
//	len(mockedPermission.GetRoleCalls())
func (mock *PermissionMock) GetRoleCalls() []struct {
	Ctx     sdk.Context
	Address sdk.AccAddress
} {
	var calls []struct {
		Ctx     sdk.Context
		Address sdk.AccAddress
	}
	mock.lockGetRole.RLock()
	calls = mock.calls.GetRole
	mock.lockGetRole.RUnlock()
	return calls
}

// Ensure, that StakingMock does implement types.Staking.
// If this is not the case, regenerate this file with moq.
var _ types.Staking = &StakingMock{}

// StakingMock is a mock implementation of types.Staking.
//
//	func TestSomethingThatUsesStaking(t *testing.T) {
//
//		// make and configure a mocked types.Staking
//		mockedStaking := &StakingMock{
//			ValidatorFunc: func(ctx sdk.Context, addr sdk.ValAddress) stakingtypes.ValidatorI {
//				panic("mock out the Validator method")
//			},
//		}
//
//		// use mockedStaking in code that requires types.Staking
//		// and then make assertions.
//
//	}
type StakingMock struct {
	// ValidatorFunc mocks the Validator method.
	ValidatorFunc func(ctx sdk.Context, addr sdk.ValAddress) stakingtypes.ValidatorI

	// calls tracks calls to the methods.
	calls struct {
		// Validator holds details about calls to the Validator method.
		Validator []struct {
			// Ctx is the ctx argument value.
			Ctx sdk.Context
			// Addr is the addr argument value.
			Addr sdk.ValAddress
		}
	}
	lockValidator sync.RWMutex
}

// Validator calls ValidatorFunc.
func (mock *StakingMock) Validator(ctx sdk.Context, addr sdk.ValAddress) stakingtypes.ValidatorI {
	if mock.ValidatorFunc == nil {
		panic("StakingMock.ValidatorFunc: method is nil but Staking.Validator was just called")
	}
	callInfo := struct {
		Ctx  sdk.Context
		Addr sdk.ValAddress
	}{
		Ctx:  ctx,
		Addr: addr,
	}
	mock.lockValidator.Lock()
	mock.calls.Validator = append(mock.calls.Validator, callInfo)
	mock.lockValidator.Unlock()
	return mock.ValidatorFunc(ctx, addr)
}

// ValidatorCalls gets all the calls that were made to Validator.
// Check the length with:
//
//	len(mockedStaking.ValidatorCalls())
func (mock *StakingMock) ValidatorCalls() []struct {
	Ctx  sdk.Context
	Addr sdk.ValAddress
} {
	var calls []struct {
		Ctx  sdk.Context
		Addr sdk.ValAddress
	}
	mock.lockValidator.RLock()
	calls = mock.calls.Validator
	mock.lockValidator.RUnlock()
	return calls
}

// Ensure, that RewardMock does implement types.Reward.
// If this is not the case, regenerate this file with moq.
var _ types.Reward = &RewardMock{}

// RewardMock is a mock implementation of types.Reward.
//
//	func TestSomethingThatUsesReward(t *testing.T) {
//
//		// make and configure a mocked types.Reward
//		mockedReward := &RewardMock{
//			SetPendingRefundFunc: func(ctx sdk.Context, req rewardtypes.RefundMsgRequest, refund rewardtypes.Refund) error {
//				panic("mock out the SetPendingRefund method")
//			},
//		}
//
//		// use mockedReward in code that requires types.Reward
//		// and then make assertions.
//
//	}
type RewardMock struct {
	// SetPendingRefundFunc mocks the SetPendingRefund method.
	SetPendingRefundFunc func(ctx sdk.Context, req rewardtypes.RefundMsgRequest, refund rewardtypes.Refund) error

	// calls tracks calls to the methods.
	calls struct {
		// SetPendingRefund holds details about calls to the SetPendingRefund method.
		SetPendingRefund []struct {
			// Ctx is the ctx argument value.
			Ctx sdk.Context
			// Req is the req argument value.
			Req rewardtypes.RefundMsgRequest
			// Refund is the refund argument value.
			Refund rewardtypes.Refund
		}
	}
	lockSetPendingRefund sync.RWMutex
}

// SetPendingRefund calls SetPendingRefundFunc.
func (mock *RewardMock) SetPendingRefund(ctx sdk.Context, req rewardtypes.RefundMsgRequest, refund rewardtypes.Refund) error {
	if mock.SetPendingRefundFunc == nil {
		panic("RewardMock.SetPendingRefundFunc: method is nil but Reward.SetPendingRefund was just called")
	}
	callInfo := struct {
		Ctx    sdk.Context
		Req    rewardtypes.RefundMsgRequest
		Refund rewardtypes.Refund
	}{
		Ctx:    ctx,
		Req:    req,
		Refund: refund,
	}
	mock.lockSetPendingRefund.Lock()
	mock.calls.SetPendingRefund = append(mock.calls.SetPendingRefund, callInfo)
	mock.lockSetPendingRefund.Unlock()
	return mock.SetPendingRefundFunc(ctx, req, refund)
}

// SetPendingRefundCalls gets all the calls that were made to SetPendingRefund.
// Check the length with:
//
//	len(mockedReward.SetPendingRefundCalls())
func (mock *RewardMock) SetPendingRefundCalls() []struct {
	Ctx    sdk.Context
	Req    rewardtypes.RefundMsgRequest
	Refund rewardtypes.Refund
} {
	var calls []struct {
		Ctx    sdk.Context
		Req    rewardtypes.RefundMsgRequest
		Refund rewardtypes.Refund
	}
	mock.lockSetPendingRefund.RLock()
	calls = mock.calls.SetPendingRefund
	mock.lockSetPendingRefund.RUnlock()
	return calls
}
