// Code generated by mockery. DO NOT EDIT.

package mocks

import (
	context "context"
	big "math/big"

	common "github.com/ethereum/go-ethereum/common"

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

	types "github.com/ethereum/go-ethereum/core/types"

	zkevm_ethtx_managertypes "github.com/0xPolygon/zkevm-ethtx-manager/types"
)

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

type EthTxManager_Expecter struct {
	mock *mock.Mock
}

func (_m *EthTxManager) EXPECT() *EthTxManager_Expecter {
	return &EthTxManager_Expecter{mock: &_m.Mock}
}

// Add provides a mock function with given fields: ctx, to, value, data, gasOffset, sidecar
func (_m *EthTxManager) Add(ctx context.Context, to *common.Address, value *big.Int, data []byte, gasOffset uint64, sidecar *types.BlobTxSidecar) (common.Hash, error) {
	ret := _m.Called(ctx, to, value, data, gasOffset, sidecar)

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

	var r0 common.Hash
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, *common.Address, *big.Int, []byte, uint64, *types.BlobTxSidecar) (common.Hash, error)); ok {
		return rf(ctx, to, value, data, gasOffset, sidecar)
	}
	if rf, ok := ret.Get(0).(func(context.Context, *common.Address, *big.Int, []byte, uint64, *types.BlobTxSidecar) common.Hash); ok {
		r0 = rf(ctx, to, value, data, gasOffset, sidecar)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(common.Hash)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, *common.Address, *big.Int, []byte, uint64, *types.BlobTxSidecar) error); ok {
		r1 = rf(ctx, to, value, data, gasOffset, sidecar)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// Add is a helper method to define mock.On call
//   - ctx context.Context
//   - to *common.Address
//   - value *big.Int
//   - data []byte
//   - gasOffset uint64
//   - sidecar *types.BlobTxSidecar
func (_e *EthTxManager_Expecter) Add(ctx interface{}, to interface{}, value interface{}, data interface{}, gasOffset interface{}, sidecar interface{}) *EthTxManager_Add_Call {
	return &EthTxManager_Add_Call{Call: _e.mock.On("Add", ctx, to, value, data, gasOffset, sidecar)}
}

func (_c *EthTxManager_Add_Call) Run(run func(ctx context.Context, to *common.Address, value *big.Int, data []byte, gasOffset uint64, sidecar *types.BlobTxSidecar)) *EthTxManager_Add_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(context.Context), args[1].(*common.Address), args[2].(*big.Int), args[3].([]byte), args[4].(uint64), args[5].(*types.BlobTxSidecar))
	})
	return _c
}

func (_c *EthTxManager_Add_Call) Return(_a0 common.Hash, _a1 error) *EthTxManager_Add_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *EthTxManager_Add_Call) RunAndReturn(run func(context.Context, *common.Address, *big.Int, []byte, uint64, *types.BlobTxSidecar) (common.Hash, error)) *EthTxManager_Add_Call {
	_c.Call.Return(run)
	return _c
}

// From provides a mock function with no fields
func (_m *EthTxManager) From() common.Address {
	ret := _m.Called()

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

	var r0 common.Address
	if rf, ok := ret.Get(0).(func() common.Address); ok {
		r0 = rf()
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(common.Address)
		}
	}

	return r0
}

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

// From is a helper method to define mock.On call
func (_e *EthTxManager_Expecter) From() *EthTxManager_From_Call {
	return &EthTxManager_From_Call{Call: _e.mock.On("From")}
}

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

func (_c *EthTxManager_From_Call) Return(_a0 common.Address) *EthTxManager_From_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *EthTxManager_From_Call) RunAndReturn(run func() common.Address) *EthTxManager_From_Call {
	_c.Call.Return(run)
	return _c
}

// Remove provides a mock function with given fields: ctx, id
func (_m *EthTxManager) Remove(ctx context.Context, id common.Hash) error {
	ret := _m.Called(ctx, id)

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

	var r0 error
	if rf, ok := ret.Get(0).(func(context.Context, common.Hash) error); ok {
		r0 = rf(ctx, id)
	} else {
		r0 = ret.Error(0)
	}

	return r0
}

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

// Remove is a helper method to define mock.On call
//   - ctx context.Context
//   - id common.Hash
func (_e *EthTxManager_Expecter) Remove(ctx interface{}, id interface{}) *EthTxManager_Remove_Call {
	return &EthTxManager_Remove_Call{Call: _e.mock.On("Remove", ctx, id)}
}

func (_c *EthTxManager_Remove_Call) Run(run func(ctx context.Context, id common.Hash)) *EthTxManager_Remove_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(context.Context), args[1].(common.Hash))
	})
	return _c
}

func (_c *EthTxManager_Remove_Call) Return(_a0 error) *EthTxManager_Remove_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *EthTxManager_Remove_Call) RunAndReturn(run func(context.Context, common.Hash) error) *EthTxManager_Remove_Call {
	_c.Call.Return(run)
	return _c
}

// Result provides a mock function with given fields: ctx, id
func (_m *EthTxManager) Result(ctx context.Context, id common.Hash) (zkevm_ethtx_managertypes.MonitoredTxResult, error) {
	ret := _m.Called(ctx, id)

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

	var r0 zkevm_ethtx_managertypes.MonitoredTxResult
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, common.Hash) (zkevm_ethtx_managertypes.MonitoredTxResult, error)); ok {
		return rf(ctx, id)
	}
	if rf, ok := ret.Get(0).(func(context.Context, common.Hash) zkevm_ethtx_managertypes.MonitoredTxResult); ok {
		r0 = rf(ctx, id)
	} else {
		r0 = ret.Get(0).(zkevm_ethtx_managertypes.MonitoredTxResult)
	}

	if rf, ok := ret.Get(1).(func(context.Context, common.Hash) error); ok {
		r1 = rf(ctx, id)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// Result is a helper method to define mock.On call
//   - ctx context.Context
//   - id common.Hash
func (_e *EthTxManager_Expecter) Result(ctx interface{}, id interface{}) *EthTxManager_Result_Call {
	return &EthTxManager_Result_Call{Call: _e.mock.On("Result", ctx, id)}
}

func (_c *EthTxManager_Result_Call) Run(run func(ctx context.Context, id common.Hash)) *EthTxManager_Result_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(context.Context), args[1].(common.Hash))
	})
	return _c
}

func (_c *EthTxManager_Result_Call) Return(_a0 zkevm_ethtx_managertypes.MonitoredTxResult, _a1 error) *EthTxManager_Result_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *EthTxManager_Result_Call) RunAndReturn(run func(context.Context, common.Hash) (zkevm_ethtx_managertypes.MonitoredTxResult, error)) *EthTxManager_Result_Call {
	_c.Call.Return(run)
	return _c
}

// ResultsByStatus provides a mock function with given fields: ctx, statuses
func (_m *EthTxManager) ResultsByStatus(ctx context.Context, statuses []zkevm_ethtx_managertypes.MonitoredTxStatus) ([]zkevm_ethtx_managertypes.MonitoredTxResult, error) {
	ret := _m.Called(ctx, statuses)

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

	var r0 []zkevm_ethtx_managertypes.MonitoredTxResult
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, []zkevm_ethtx_managertypes.MonitoredTxStatus) ([]zkevm_ethtx_managertypes.MonitoredTxResult, error)); ok {
		return rf(ctx, statuses)
	}
	if rf, ok := ret.Get(0).(func(context.Context, []zkevm_ethtx_managertypes.MonitoredTxStatus) []zkevm_ethtx_managertypes.MonitoredTxResult); ok {
		r0 = rf(ctx, statuses)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).([]zkevm_ethtx_managertypes.MonitoredTxResult)
		}
	}

	if rf, ok := ret.Get(1).(func(context.Context, []zkevm_ethtx_managertypes.MonitoredTxStatus) error); ok {
		r1 = rf(ctx, statuses)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// ResultsByStatus is a helper method to define mock.On call
//   - ctx context.Context
//   - statuses []zkevm_ethtx_managertypes.MonitoredTxStatus
func (_e *EthTxManager_Expecter) ResultsByStatus(ctx interface{}, statuses interface{}) *EthTxManager_ResultsByStatus_Call {
	return &EthTxManager_ResultsByStatus_Call{Call: _e.mock.On("ResultsByStatus", ctx, statuses)}
}

func (_c *EthTxManager_ResultsByStatus_Call) Run(run func(ctx context.Context, statuses []zkevm_ethtx_managertypes.MonitoredTxStatus)) *EthTxManager_ResultsByStatus_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(context.Context), args[1].([]zkevm_ethtx_managertypes.MonitoredTxStatus))
	})
	return _c
}

func (_c *EthTxManager_ResultsByStatus_Call) Return(_a0 []zkevm_ethtx_managertypes.MonitoredTxResult, _a1 error) *EthTxManager_ResultsByStatus_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *EthTxManager_ResultsByStatus_Call) RunAndReturn(run func(context.Context, []zkevm_ethtx_managertypes.MonitoredTxStatus) ([]zkevm_ethtx_managertypes.MonitoredTxResult, error)) *EthTxManager_ResultsByStatus_Call {
	_c.Call.Return(run)
	return _c
}

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

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

	return mock
}
