-
Notifications
You must be signed in to change notification settings - Fork 0
/
TxBuilder.go
140 lines (110 loc) · 3.26 KB
/
TxBuilder.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
// Code generated by mockery v2.14.0. DO NOT EDIT.
package mocks
import (
mock "github.com/stretchr/testify/mock"
signing "github.com/cosmos/cosmos-sdk/x/auth/signing"
tx "github.com/cosmos/cosmos-sdk/types/tx"
txsigning "github.com/cosmos/cosmos-sdk/types/tx/signing"
types "github.com/cosmos/cosmos-sdk/types"
)
// TxBuilder is an autogenerated mock type for the TxBuilder type
type TxBuilder struct {
mock.Mock
}
// AddAuxSignerData provides a mock function with given fields: _a0
func (_m *TxBuilder) AddAuxSignerData(_a0 tx.AuxSignerData) error {
ret := _m.Called(_a0)
var r0 error
if rf, ok := ret.Get(0).(func(tx.AuxSignerData) error); ok {
r0 = rf(_a0)
} else {
r0 = ret.Error(0)
}
return r0
}
// GetTx provides a mock function with given fields:
func (_m *TxBuilder) GetTx() signing.Tx {
ret := _m.Called()
var r0 signing.Tx
if rf, ok := ret.Get(0).(func() signing.Tx); ok {
r0 = rf()
} else {
if ret.Get(0) != nil {
r0 = ret.Get(0).(signing.Tx)
}
}
return r0
}
// SetFeeAmount provides a mock function with given fields: amount
func (_m *TxBuilder) SetFeeAmount(amount types.Coins) {
_m.Called(amount)
}
// SetFeeGranter provides a mock function with given fields: feeGranter
func (_m *TxBuilder) SetFeeGranter(feeGranter types.AccAddress) {
_m.Called(feeGranter)
}
// SetFeePayer provides a mock function with given fields: feePayer
func (_m *TxBuilder) SetFeePayer(feePayer types.AccAddress) {
_m.Called(feePayer)
}
// SetGasLimit provides a mock function with given fields: limit
func (_m *TxBuilder) SetGasLimit(limit uint64) {
_m.Called(limit)
}
// SetMemo provides a mock function with given fields: memo
func (_m *TxBuilder) SetMemo(memo string) {
_m.Called(memo)
}
// SetMsgs provides a mock function with given fields: msgs
func (_m *TxBuilder) SetMsgs(msgs ...types.Msg) error {
_va := make([]interface{}, len(msgs))
for _i := range msgs {
_va[_i] = msgs[_i]
}
var _ca []interface{}
_ca = append(_ca, _va...)
ret := _m.Called(_ca...)
var r0 error
if rf, ok := ret.Get(0).(func(...types.Msg) error); ok {
r0 = rf(msgs...)
} else {
r0 = ret.Error(0)
}
return r0
}
// SetSignatures provides a mock function with given fields: signatures
func (_m *TxBuilder) SetSignatures(signatures ...txsigning.SignatureV2) error {
_va := make([]interface{}, len(signatures))
for _i := range signatures {
_va[_i] = signatures[_i]
}
var _ca []interface{}
_ca = append(_ca, _va...)
ret := _m.Called(_ca...)
var r0 error
if rf, ok := ret.Get(0).(func(...txsigning.SignatureV2) error); ok {
r0 = rf(signatures...)
} else {
r0 = ret.Error(0)
}
return r0
}
// SetTimeoutHeight provides a mock function with given fields: height
func (_m *TxBuilder) SetTimeoutHeight(height uint64) {
_m.Called(height)
}
// SetTip provides a mock function with given fields: tip
func (_m *TxBuilder) SetTip(tip *tx.Tip) {
_m.Called(tip)
}
type mockConstructorTestingTNewTxBuilder interface {
mock.TestingT
Cleanup(func())
}
// NewTxBuilder creates a new instance of TxBuilder. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
func NewTxBuilder(t mockConstructorTestingTNewTxBuilder) *TxBuilder {
mock := &TxBuilder{}
mock.Mock.Test(t)
t.Cleanup(func() { mock.AssertExpectations(t) })
return mock
}