forked from coinbase/mesh-sdk-go
/
broadcast_storage_handler.go
74 lines (56 loc) · 2.58 KB
/
broadcast_storage_handler.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
// Code generated by mockery v2.13.1. DO NOT EDIT.
package modules
import (
context "context"
mock "github.com/stretchr/testify/mock"
database "github.com/findoranetwork/rosetta-sdk-go/storage/database"
types "github.com/findoranetwork/rosetta-sdk-go/types"
)
// BroadcastStorageHandler is an autogenerated mock type for the BroadcastStorageHandler type
type BroadcastStorageHandler struct {
mock.Mock
}
// BroadcastFailed provides a mock function with given fields: _a0, _a1, _a2, _a3, _a4
func (_m *BroadcastStorageHandler) BroadcastFailed(_a0 context.Context, _a1 database.Transaction, _a2 string, _a3 *types.TransactionIdentifier, _a4 []*types.Operation) error {
ret := _m.Called(_a0, _a1, _a2, _a3, _a4)
var r0 error
if rf, ok := ret.Get(0).(func(context.Context, database.Transaction, string, *types.TransactionIdentifier, []*types.Operation) error); ok {
r0 = rf(_a0, _a1, _a2, _a3, _a4)
} else {
r0 = ret.Error(0)
}
return r0
}
// TransactionConfirmed provides a mock function with given fields: _a0, _a1, _a2, _a3, _a4, _a5, _a6
func (_m *BroadcastStorageHandler) TransactionConfirmed(_a0 context.Context, _a1 database.Transaction, _a2 string, _a3 *types.BlockIdentifier, _a4 *types.Transaction, _a5 []*types.Operation, _a6 map[string]interface{}) error {
ret := _m.Called(_a0, _a1, _a2, _a3, _a4, _a5, _a6)
var r0 error
if rf, ok := ret.Get(0).(func(context.Context, database.Transaction, string, *types.BlockIdentifier, *types.Transaction, []*types.Operation, map[string]interface{}) error); ok {
r0 = rf(_a0, _a1, _a2, _a3, _a4, _a5, _a6)
} else {
r0 = ret.Error(0)
}
return r0
}
// TransactionStale provides a mock function with given fields: _a0, _a1, _a2, _a3
func (_m *BroadcastStorageHandler) TransactionStale(_a0 context.Context, _a1 database.Transaction, _a2 string, _a3 *types.TransactionIdentifier) error {
ret := _m.Called(_a0, _a1, _a2, _a3)
var r0 error
if rf, ok := ret.Get(0).(func(context.Context, database.Transaction, string, *types.TransactionIdentifier) error); ok {
r0 = rf(_a0, _a1, _a2, _a3)
} else {
r0 = ret.Error(0)
}
return r0
}
type mockConstructorTestingTNewBroadcastStorageHandler interface {
mock.TestingT
Cleanup(func())
}
// NewBroadcastStorageHandler creates a new instance of BroadcastStorageHandler. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
func NewBroadcastStorageHandler(t mockConstructorTestingTNewBroadcastStorageHandler) *BroadcastStorageHandler {
mock := &BroadcastStorageHandler{}
mock.Mock.Test(t)
t.Cleanup(func() { mock.AssertExpectations(t) })
return mock
}