-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmock.go
50 lines (39 loc) · 960 Bytes
/
mock.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
package apollo
import agollo "github.com/philchia/agollo/v4"
// MockClient ...
type MockClient struct{}
// Start ...
func (c *MockClient) Start() error {
return nil
}
// Stop ...
func (c *MockClient) Stop() error {
return nil
}
// OnUpdate ...
func (c *MockClient) OnUpdate(f func(*agollo.ChangeEvent)) {
}
// GetString ...
func (c *MockClient) GetString(key string, opts ...agollo.OpOption) string {
return ""
}
// GetContent ...
func (c *MockClient) GetContent(opts ...agollo.OpOption) string {
return ""
}
// GetPropertiesContent ...
func (c *MockClient) GetPropertiesContent(opts ...agollo.OpOption) string {
return ""
}
// GetAllKeys ...
func (c *MockClient) GetAllKeys(opts ...agollo.OpOption) []string {
return nil
}
// GetReleaseKey ...
func (c *MockClient) GetReleaseKey(opts ...agollo.OpOption) string {
return ""
}
// SubscribeToNamespaces ...
func (c *MockClient) SubscribeToNamespaces(namespaces ...string) error {
return nil
}