// Code generated by mockery v2.40.1. DO NOT EDIT.

package mocks

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

	types "github.com/cosmos/cosmos-sdk/types"
)

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

type TxBroadcaster_Expecter struct {
	mock *mock.Mock
}

func (_m *TxBroadcaster) EXPECT() *TxBroadcaster_Expecter {
	return &TxBroadcaster_Expecter{mock: &_m.Mock}
}

// BroadcastTxSync provides a mock function with given fields: txBytes
func (_m *TxBroadcaster) BroadcastTxSync(txBytes []byte) (*types.TxResponse, error) {
	ret := _m.Called(txBytes)

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

	var r0 *types.TxResponse
	var r1 error
	if rf, ok := ret.Get(0).(func([]byte) (*types.TxResponse, error)); ok {
		return rf(txBytes)
	}
	if rf, ok := ret.Get(0).(func([]byte) *types.TxResponse); ok {
		r0 = rf(txBytes)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(*types.TxResponse)
		}
	}

	if rf, ok := ret.Get(1).(func([]byte) error); ok {
		r1 = rf(txBytes)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// BroadcastTxSync is a helper method to define mock.On call
//   - txBytes []byte
func (_e *TxBroadcaster_Expecter) BroadcastTxSync(txBytes interface{}) *TxBroadcaster_BroadcastTxSync_Call {
	return &TxBroadcaster_BroadcastTxSync_Call{Call: _e.mock.On("BroadcastTxSync", txBytes)}
}

func (_c *TxBroadcaster_BroadcastTxSync_Call) Run(run func(txBytes []byte)) *TxBroadcaster_BroadcastTxSync_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].([]byte))
	})
	return _c
}

func (_c *TxBroadcaster_BroadcastTxSync_Call) Return(res *types.TxResponse, err error) *TxBroadcaster_BroadcastTxSync_Call {
	_c.Call.Return(res, err)
	return _c
}

func (_c *TxBroadcaster_BroadcastTxSync_Call) RunAndReturn(run func([]byte) (*types.TxResponse, error)) *TxBroadcaster_BroadcastTxSync_Call {
	_c.Call.Return(run)
	return _c
}

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

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

	return mock
}
