-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathspaces_mock_test.go
261 lines (222 loc) · 8.57 KB
/
spaces_mock_test.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
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
// Code generated by MockGen. DO NOT EDIT.
// Source: github.com/juju/juju/environs/space (interfaces: ReloadSpacesState,Space,Constraints)
//
// Generated by this command:
//
// mockgen -package space -destination spaces_mock_test.go github.com/juju/juju/environs/space ReloadSpacesState,Space,Constraints
//
// Package space is a generated GoMock package.
package space
import (
reflect "reflect"
set "github.com/juju/collections/set"
network "github.com/juju/juju/core/network"
state "github.com/juju/juju/state"
gomock "go.uber.org/mock/gomock"
)
// MockReloadSpacesState is a mock of ReloadSpacesState interface.
type MockReloadSpacesState struct {
ctrl *gomock.Controller
recorder *MockReloadSpacesStateMockRecorder
}
// MockReloadSpacesStateMockRecorder is the mock recorder for MockReloadSpacesState.
type MockReloadSpacesStateMockRecorder struct {
mock *MockReloadSpacesState
}
// NewMockReloadSpacesState creates a new mock instance.
func NewMockReloadSpacesState(ctrl *gomock.Controller) *MockReloadSpacesState {
mock := &MockReloadSpacesState{ctrl: ctrl}
mock.recorder = &MockReloadSpacesStateMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockReloadSpacesState) EXPECT() *MockReloadSpacesStateMockRecorder {
return m.recorder
}
// AddSpace mocks base method.
func (m *MockReloadSpacesState) AddSpace(arg0 string, arg1 network.Id, arg2 []string, arg3 bool) (Space, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "AddSpace", arg0, arg1, arg2, arg3)
ret0, _ := ret[0].(Space)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// AddSpace indicates an expected call of AddSpace.
func (mr *MockReloadSpacesStateMockRecorder) AddSpace(arg0, arg1, arg2, arg3 any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddSpace", reflect.TypeOf((*MockReloadSpacesState)(nil).AddSpace), arg0, arg1, arg2, arg3)
}
// AllEndpointBindingsSpaceNames mocks base method.
func (m *MockReloadSpacesState) AllEndpointBindingsSpaceNames() (set.Strings, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "AllEndpointBindingsSpaceNames")
ret0, _ := ret[0].(set.Strings)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// AllEndpointBindingsSpaceNames indicates an expected call of AllEndpointBindingsSpaceNames.
func (mr *MockReloadSpacesStateMockRecorder) AllEndpointBindingsSpaceNames() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AllEndpointBindingsSpaceNames", reflect.TypeOf((*MockReloadSpacesState)(nil).AllEndpointBindingsSpaceNames))
}
// AllSpaces mocks base method.
func (m *MockReloadSpacesState) AllSpaces() ([]Space, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "AllSpaces")
ret0, _ := ret[0].([]Space)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// AllSpaces indicates an expected call of AllSpaces.
func (mr *MockReloadSpacesStateMockRecorder) AllSpaces() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AllSpaces", reflect.TypeOf((*MockReloadSpacesState)(nil).AllSpaces))
}
// ConstraintsBySpaceName mocks base method.
func (m *MockReloadSpacesState) ConstraintsBySpaceName(arg0 string) ([]Constraints, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ConstraintsBySpaceName", arg0)
ret0, _ := ret[0].([]Constraints)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// ConstraintsBySpaceName indicates an expected call of ConstraintsBySpaceName.
func (mr *MockReloadSpacesStateMockRecorder) ConstraintsBySpaceName(arg0 any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ConstraintsBySpaceName", reflect.TypeOf((*MockReloadSpacesState)(nil).ConstraintsBySpaceName), arg0)
}
// DefaultEndpointBindingSpace mocks base method.
func (m *MockReloadSpacesState) DefaultEndpointBindingSpace() (string, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "DefaultEndpointBindingSpace")
ret0, _ := ret[0].(string)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// DefaultEndpointBindingSpace indicates an expected call of DefaultEndpointBindingSpace.
func (mr *MockReloadSpacesStateMockRecorder) DefaultEndpointBindingSpace() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DefaultEndpointBindingSpace", reflect.TypeOf((*MockReloadSpacesState)(nil).DefaultEndpointBindingSpace))
}
// SaveProviderSubnets mocks base method.
func (m *MockReloadSpacesState) SaveProviderSubnets(arg0 []network.SubnetInfo, arg1 string) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "SaveProviderSubnets", arg0, arg1)
ret0, _ := ret[0].(error)
return ret0
}
// SaveProviderSubnets indicates an expected call of SaveProviderSubnets.
func (mr *MockReloadSpacesStateMockRecorder) SaveProviderSubnets(arg0, arg1 any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SaveProviderSubnets", reflect.TypeOf((*MockReloadSpacesState)(nil).SaveProviderSubnets), arg0, arg1)
}
// MockSpace is a mock of Space interface.
type MockSpace struct {
ctrl *gomock.Controller
recorder *MockSpaceMockRecorder
}
// MockSpaceMockRecorder is the mock recorder for MockSpace.
type MockSpaceMockRecorder struct {
mock *MockSpace
}
// NewMockSpace creates a new mock instance.
func NewMockSpace(ctrl *gomock.Controller) *MockSpace {
mock := &MockSpace{ctrl: ctrl}
mock.recorder = &MockSpaceMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockSpace) EXPECT() *MockSpaceMockRecorder {
return m.recorder
}
// EnsureDead mocks base method.
func (m *MockSpace) EnsureDead() error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "EnsureDead")
ret0, _ := ret[0].(error)
return ret0
}
// EnsureDead indicates an expected call of EnsureDead.
func (mr *MockSpaceMockRecorder) EnsureDead() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "EnsureDead", reflect.TypeOf((*MockSpace)(nil).EnsureDead))
}
// Id mocks base method.
func (m *MockSpace) Id() string {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Id")
ret0, _ := ret[0].(string)
return ret0
}
// Id indicates an expected call of Id.
func (mr *MockSpaceMockRecorder) Id() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Id", reflect.TypeOf((*MockSpace)(nil).Id))
}
// Life mocks base method.
func (m *MockSpace) Life() state.Life {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Life")
ret0, _ := ret[0].(state.Life)
return ret0
}
// Life indicates an expected call of Life.
func (mr *MockSpaceMockRecorder) Life() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Life", reflect.TypeOf((*MockSpace)(nil).Life))
}
// Name mocks base method.
func (m *MockSpace) Name() string {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Name")
ret0, _ := ret[0].(string)
return ret0
}
// Name indicates an expected call of Name.
func (mr *MockSpaceMockRecorder) Name() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Name", reflect.TypeOf((*MockSpace)(nil).Name))
}
// ProviderId mocks base method.
func (m *MockSpace) ProviderId() network.Id {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ProviderId")
ret0, _ := ret[0].(network.Id)
return ret0
}
// ProviderId indicates an expected call of ProviderId.
func (mr *MockSpaceMockRecorder) ProviderId() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ProviderId", reflect.TypeOf((*MockSpace)(nil).ProviderId))
}
// Remove mocks base method.
func (m *MockSpace) Remove() error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Remove")
ret0, _ := ret[0].(error)
return ret0
}
// Remove indicates an expected call of Remove.
func (mr *MockSpaceMockRecorder) Remove() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Remove", reflect.TypeOf((*MockSpace)(nil).Remove))
}
// MockConstraints is a mock of Constraints interface.
type MockConstraints struct {
ctrl *gomock.Controller
recorder *MockConstraintsMockRecorder
}
// MockConstraintsMockRecorder is the mock recorder for MockConstraints.
type MockConstraintsMockRecorder struct {
mock *MockConstraints
}
// NewMockConstraints creates a new mock instance.
func NewMockConstraints(ctrl *gomock.Controller) *MockConstraints {
mock := &MockConstraints{ctrl: ctrl}
mock.recorder = &MockConstraintsMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockConstraints) EXPECT() *MockConstraintsMockRecorder {
return m.recorder
}