github.com/ava-labs/avalanchego@v1.11.11/vms/avm/state/statemock/chain.go (about) 1 // Code generated by MockGen. DO NOT EDIT. 2 // Source: github.com/ava-labs/avalanchego/vms/avm/state (interfaces: Chain) 3 // 4 // Generated by this command: 5 // 6 // mockgen -package=statemock -destination=vms/avm/state/statemock/chain.go -mock_names=Chain=Chain github.com/ava-labs/avalanchego/vms/avm/state Chain 7 // 8 9 // Package statemock is a generated GoMock package. 10 package statemock 11 12 import ( 13 reflect "reflect" 14 time "time" 15 16 ids "github.com/ava-labs/avalanchego/ids" 17 block "github.com/ava-labs/avalanchego/vms/avm/block" 18 txs "github.com/ava-labs/avalanchego/vms/avm/txs" 19 avax "github.com/ava-labs/avalanchego/vms/components/avax" 20 gomock "go.uber.org/mock/gomock" 21 ) 22 23 // Chain is a mock of Chain interface. 24 type Chain struct { 25 ctrl *gomock.Controller 26 recorder *ChainMockRecorder 27 } 28 29 // ChainMockRecorder is the mock recorder for Chain. 30 type ChainMockRecorder struct { 31 mock *Chain 32 } 33 34 // NewChain creates a new mock instance. 35 func NewChain(ctrl *gomock.Controller) *Chain { 36 mock := &Chain{ctrl: ctrl} 37 mock.recorder = &ChainMockRecorder{mock} 38 return mock 39 } 40 41 // EXPECT returns an object that allows the caller to indicate expected use. 42 func (m *Chain) EXPECT() *ChainMockRecorder { 43 return m.recorder 44 } 45 46 // AddBlock mocks base method. 47 func (m *Chain) AddBlock(arg0 block.Block) { 48 m.ctrl.T.Helper() 49 m.ctrl.Call(m, "AddBlock", arg0) 50 } 51 52 // AddBlock indicates an expected call of AddBlock. 53 func (mr *ChainMockRecorder) AddBlock(arg0 any) *gomock.Call { 54 mr.mock.ctrl.T.Helper() 55 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddBlock", reflect.TypeOf((*Chain)(nil).AddBlock), arg0) 56 } 57 58 // AddTx mocks base method. 59 func (m *Chain) AddTx(arg0 *txs.Tx) { 60 m.ctrl.T.Helper() 61 m.ctrl.Call(m, "AddTx", arg0) 62 } 63 64 // AddTx indicates an expected call of AddTx. 65 func (mr *ChainMockRecorder) AddTx(arg0 any) *gomock.Call { 66 mr.mock.ctrl.T.Helper() 67 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddTx", reflect.TypeOf((*Chain)(nil).AddTx), arg0) 68 } 69 70 // AddUTXO mocks base method. 71 func (m *Chain) AddUTXO(arg0 *avax.UTXO) { 72 m.ctrl.T.Helper() 73 m.ctrl.Call(m, "AddUTXO", arg0) 74 } 75 76 // AddUTXO indicates an expected call of AddUTXO. 77 func (mr *ChainMockRecorder) AddUTXO(arg0 any) *gomock.Call { 78 mr.mock.ctrl.T.Helper() 79 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddUTXO", reflect.TypeOf((*Chain)(nil).AddUTXO), arg0) 80 } 81 82 // DeleteUTXO mocks base method. 83 func (m *Chain) DeleteUTXO(arg0 ids.ID) { 84 m.ctrl.T.Helper() 85 m.ctrl.Call(m, "DeleteUTXO", arg0) 86 } 87 88 // DeleteUTXO indicates an expected call of DeleteUTXO. 89 func (mr *ChainMockRecorder) DeleteUTXO(arg0 any) *gomock.Call { 90 mr.mock.ctrl.T.Helper() 91 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteUTXO", reflect.TypeOf((*Chain)(nil).DeleteUTXO), arg0) 92 } 93 94 // GetBlock mocks base method. 95 func (m *Chain) GetBlock(arg0 ids.ID) (block.Block, error) { 96 m.ctrl.T.Helper() 97 ret := m.ctrl.Call(m, "GetBlock", arg0) 98 ret0, _ := ret[0].(block.Block) 99 ret1, _ := ret[1].(error) 100 return ret0, ret1 101 } 102 103 // GetBlock indicates an expected call of GetBlock. 104 func (mr *ChainMockRecorder) GetBlock(arg0 any) *gomock.Call { 105 mr.mock.ctrl.T.Helper() 106 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetBlock", reflect.TypeOf((*Chain)(nil).GetBlock), arg0) 107 } 108 109 // GetBlockIDAtHeight mocks base method. 110 func (m *Chain) GetBlockIDAtHeight(arg0 uint64) (ids.ID, error) { 111 m.ctrl.T.Helper() 112 ret := m.ctrl.Call(m, "GetBlockIDAtHeight", arg0) 113 ret0, _ := ret[0].(ids.ID) 114 ret1, _ := ret[1].(error) 115 return ret0, ret1 116 } 117 118 // GetBlockIDAtHeight indicates an expected call of GetBlockIDAtHeight. 119 func (mr *ChainMockRecorder) GetBlockIDAtHeight(arg0 any) *gomock.Call { 120 mr.mock.ctrl.T.Helper() 121 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetBlockIDAtHeight", reflect.TypeOf((*Chain)(nil).GetBlockIDAtHeight), arg0) 122 } 123 124 // GetLastAccepted mocks base method. 125 func (m *Chain) GetLastAccepted() ids.ID { 126 m.ctrl.T.Helper() 127 ret := m.ctrl.Call(m, "GetLastAccepted") 128 ret0, _ := ret[0].(ids.ID) 129 return ret0 130 } 131 132 // GetLastAccepted indicates an expected call of GetLastAccepted. 133 func (mr *ChainMockRecorder) GetLastAccepted() *gomock.Call { 134 mr.mock.ctrl.T.Helper() 135 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetLastAccepted", reflect.TypeOf((*Chain)(nil).GetLastAccepted)) 136 } 137 138 // GetTimestamp mocks base method. 139 func (m *Chain) GetTimestamp() time.Time { 140 m.ctrl.T.Helper() 141 ret := m.ctrl.Call(m, "GetTimestamp") 142 ret0, _ := ret[0].(time.Time) 143 return ret0 144 } 145 146 // GetTimestamp indicates an expected call of GetTimestamp. 147 func (mr *ChainMockRecorder) GetTimestamp() *gomock.Call { 148 mr.mock.ctrl.T.Helper() 149 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetTimestamp", reflect.TypeOf((*Chain)(nil).GetTimestamp)) 150 } 151 152 // GetTx mocks base method. 153 func (m *Chain) GetTx(arg0 ids.ID) (*txs.Tx, error) { 154 m.ctrl.T.Helper() 155 ret := m.ctrl.Call(m, "GetTx", arg0) 156 ret0, _ := ret[0].(*txs.Tx) 157 ret1, _ := ret[1].(error) 158 return ret0, ret1 159 } 160 161 // GetTx indicates an expected call of GetTx. 162 func (mr *ChainMockRecorder) GetTx(arg0 any) *gomock.Call { 163 mr.mock.ctrl.T.Helper() 164 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetTx", reflect.TypeOf((*Chain)(nil).GetTx), arg0) 165 } 166 167 // GetUTXO mocks base method. 168 func (m *Chain) GetUTXO(arg0 ids.ID) (*avax.UTXO, error) { 169 m.ctrl.T.Helper() 170 ret := m.ctrl.Call(m, "GetUTXO", arg0) 171 ret0, _ := ret[0].(*avax.UTXO) 172 ret1, _ := ret[1].(error) 173 return ret0, ret1 174 } 175 176 // GetUTXO indicates an expected call of GetUTXO. 177 func (mr *ChainMockRecorder) GetUTXO(arg0 any) *gomock.Call { 178 mr.mock.ctrl.T.Helper() 179 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetUTXO", reflect.TypeOf((*Chain)(nil).GetUTXO), arg0) 180 } 181 182 // SetLastAccepted mocks base method. 183 func (m *Chain) SetLastAccepted(arg0 ids.ID) { 184 m.ctrl.T.Helper() 185 m.ctrl.Call(m, "SetLastAccepted", arg0) 186 } 187 188 // SetLastAccepted indicates an expected call of SetLastAccepted. 189 func (mr *ChainMockRecorder) SetLastAccepted(arg0 any) *gomock.Call { 190 mr.mock.ctrl.T.Helper() 191 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetLastAccepted", reflect.TypeOf((*Chain)(nil).SetLastAccepted), arg0) 192 } 193 194 // SetTimestamp mocks base method. 195 func (m *Chain) SetTimestamp(arg0 time.Time) { 196 m.ctrl.T.Helper() 197 m.ctrl.Call(m, "SetTimestamp", arg0) 198 } 199 200 // SetTimestamp indicates an expected call of SetTimestamp. 201 func (mr *ChainMockRecorder) SetTimestamp(arg0 any) *gomock.Call { 202 mr.mock.ctrl.T.Helper() 203 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetTimestamp", reflect.TypeOf((*Chain)(nil).SetTimestamp), arg0) 204 }