github.com/line/ostracon@v1.0.10-0.20230328032236-7f20145f065d/p2p/mocks/node_info.go (about)

     1  // Code generated by mockery v2.16.0. DO NOT EDIT.
     2  
     3  package mocks
     4  
     5  import (
     6  	p2p "github.com/line/ostracon/p2p"
     7  	mock "github.com/stretchr/testify/mock"
     8  )
     9  
    10  // NodeInfo is an autogenerated mock type for the NodeInfo type
    11  type NodeInfo struct {
    12  	mock.Mock
    13  }
    14  
    15  // CompatibleWith provides a mock function with given fields: other
    16  func (_m *NodeInfo) CompatibleWith(other p2p.NodeInfo) error {
    17  	ret := _m.Called(other)
    18  
    19  	var r0 error
    20  	if rf, ok := ret.Get(0).(func(p2p.NodeInfo) error); ok {
    21  		r0 = rf(other)
    22  	} else {
    23  		r0 = ret.Error(0)
    24  	}
    25  
    26  	return r0
    27  }
    28  
    29  // ID provides a mock function with given fields:
    30  func (_m *NodeInfo) ID() p2p.ID {
    31  	ret := _m.Called()
    32  
    33  	var r0 p2p.ID
    34  	if rf, ok := ret.Get(0).(func() p2p.ID); ok {
    35  		r0 = rf()
    36  	} else {
    37  		r0 = ret.Get(0).(p2p.ID)
    38  	}
    39  
    40  	return r0
    41  }
    42  
    43  // NetAddress provides a mock function with given fields:
    44  func (_m *NodeInfo) NetAddress() (*p2p.NetAddress, error) {
    45  	ret := _m.Called()
    46  
    47  	var r0 *p2p.NetAddress
    48  	if rf, ok := ret.Get(0).(func() *p2p.NetAddress); ok {
    49  		r0 = rf()
    50  	} else {
    51  		if ret.Get(0) != nil {
    52  			r0 = ret.Get(0).(*p2p.NetAddress)
    53  		}
    54  	}
    55  
    56  	var r1 error
    57  	if rf, ok := ret.Get(1).(func() error); ok {
    58  		r1 = rf()
    59  	} else {
    60  		r1 = ret.Error(1)
    61  	}
    62  
    63  	return r0, r1
    64  }
    65  
    66  // Validate provides a mock function with given fields:
    67  func (_m *NodeInfo) Validate() error {
    68  	ret := _m.Called()
    69  
    70  	var r0 error
    71  	if rf, ok := ret.Get(0).(func() error); ok {
    72  		r0 = rf()
    73  	} else {
    74  		r0 = ret.Error(0)
    75  	}
    76  
    77  	return r0
    78  }
    79  
    80  type mockConstructorTestingTNewNodeInfo interface {
    81  	mock.TestingT
    82  	Cleanup(func())
    83  }
    84  
    85  // NewNodeInfo creates a new instance of NodeInfo. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
    86  func NewNodeInfo(t mockConstructorTestingTNewNodeInfo) *NodeInfo {
    87  	mock := &NodeInfo{}
    88  	mock.Mock.Test(t)
    89  
    90  	t.Cleanup(func() { mock.AssertExpectations(t) })
    91  
    92  	return mock
    93  }