-
Notifications
You must be signed in to change notification settings - Fork 70
/
Copy pathmocks.go
117 lines (88 loc) · 2.88 KB
/
mocks.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
//revive:disable:exported
package cloudwrapper
import (
"context"
"github.com/stretchr/testify/mock"
)
type Mock struct {
mock.Mock
}
var _ CloudWrapper = &Mock{}
func (m *Mock) ListCapacities(ctx context.Context, req ListCapacitiesRequest) (*ListCapacitiesResponse, error) {
args := m.Called(ctx, req)
if args.Get(0) == nil {
return nil, args.Error(1)
}
return args.Get(0).(*ListCapacitiesResponse), args.Error(1)
}
func (m *Mock) ListLocations(ctx context.Context) (*ListLocationResponse, error) {
args := m.Called(ctx)
if args.Get(0) == nil {
return nil, args.Error(1)
}
return args.Get(0).(*ListLocationResponse), args.Error(1)
}
func (m *Mock) ListAuthKeys(ctx context.Context, req ListAuthKeysRequest) (*ListAuthKeysResponse, error) {
args := m.Called(ctx, req)
if args.Get(0) == nil {
return nil, args.Error(1)
}
return args.Get(0).(*ListAuthKeysResponse), args.Error(1)
}
func (m *Mock) ListCDNProviders(ctx context.Context) (*ListCDNProvidersResponse, error) {
args := m.Called(ctx)
if args.Get(0) == nil {
return nil, args.Error(1)
}
return args.Get(0).(*ListCDNProvidersResponse), args.Error(1)
}
func (m *Mock) ListProperties(ctx context.Context, r ListPropertiesRequest) (*ListPropertiesResponse, error) {
args := m.Called(ctx, r)
if args.Error(1) != nil {
return nil, args.Error(1)
}
return args.Get(0).(*ListPropertiesResponse), args.Error(1)
}
func (m *Mock) ListOrigins(ctx context.Context, r ListOriginsRequest) (*ListOriginsResponse, error) {
args := m.Called(ctx, r)
if args.Error(1) != nil {
return nil, args.Error(1)
}
return args.Get(0).(*ListOriginsResponse), args.Error(1)
}
func (m *Mock) GetConfiguration(ctx context.Context, r GetConfigurationRequest) (*Configuration, error) {
args := m.Called(ctx, r)
if args.Error(1) != nil {
return nil, args.Error(1)
}
return args.Get(0).(*Configuration), args.Error(1)
}
func (m *Mock) ListConfigurations(ctx context.Context) (*ListConfigurationsResponse, error) {
args := m.Called(ctx)
if args.Error(1) != nil {
return nil, args.Error(1)
}
return args.Get(0).(*ListConfigurationsResponse), args.Error(1)
}
func (m *Mock) CreateConfiguration(ctx context.Context, r CreateConfigurationRequest) (*Configuration, error) {
args := m.Called(ctx, r)
if args.Error(1) != nil {
return nil, args.Error(1)
}
return args.Get(0).(*Configuration), args.Error(1)
}
func (m *Mock) UpdateConfiguration(ctx context.Context, r UpdateConfigurationRequest) (*Configuration, error) {
args := m.Called(ctx, r)
if args.Error(1) != nil {
return nil, args.Error(1)
}
return args.Get(0).(*Configuration), args.Error(1)
}
func (m *Mock) DeleteConfiguration(ctx context.Context, r DeleteConfigurationRequest) error {
args := m.Called(ctx, r)
return args.Error(0)
}
func (m *Mock) ActivateConfiguration(ctx context.Context, r ActivateConfigurationRequest) error {
args := m.Called(ctx, r)
return args.Error(0)
}