-
Notifications
You must be signed in to change notification settings - Fork 162
/
fake_session_context.go
134 lines (118 loc) · 3.39 KB
/
fake_session_context.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
// This file was generated by counterfeiter
package fakes
import (
"sync"
"github.com/cloudfoundry/bosh-cli/cmd"
cmdconf "github.com/cloudfoundry/bosh-cli/cmd/config"
)
type FakeSessionContext struct {
EnvironmentStub func() string
environmentMutex sync.RWMutex
environmentArgsForCall []struct{}
environmentReturns struct {
result1 string
}
CACertStub func() string
cACertMutex sync.RWMutex
cACertArgsForCall []struct{}
cACertReturns struct {
result1 string
}
CredentialsStub func() cmdconf.Creds
credentialsMutex sync.RWMutex
credentialsArgsForCall []struct{}
credentialsReturns struct {
result1 cmdconf.Creds
}
DeploymentStub func() string
deploymentMutex sync.RWMutex
deploymentArgsForCall []struct{}
deploymentReturns struct {
result1 string
}
}
func (fake *FakeSessionContext) Environment() string {
fake.environmentMutex.Lock()
fake.environmentArgsForCall = append(fake.environmentArgsForCall, struct{}{})
fake.environmentMutex.Unlock()
if fake.EnvironmentStub != nil {
return fake.EnvironmentStub()
} else {
return fake.environmentReturns.result1
}
}
func (fake *FakeSessionContext) EnvironmentCallCount() int {
fake.environmentMutex.RLock()
defer fake.environmentMutex.RUnlock()
return len(fake.environmentArgsForCall)
}
func (fake *FakeSessionContext) EnvironmentReturns(result1 string) {
fake.EnvironmentStub = nil
fake.environmentReturns = struct {
result1 string
}{result1}
}
func (fake *FakeSessionContext) CACert() string {
fake.cACertMutex.Lock()
fake.cACertArgsForCall = append(fake.cACertArgsForCall, struct{}{})
fake.cACertMutex.Unlock()
if fake.CACertStub != nil {
return fake.CACertStub()
} else {
return fake.cACertReturns.result1
}
}
func (fake *FakeSessionContext) CACertCallCount() int {
fake.cACertMutex.RLock()
defer fake.cACertMutex.RUnlock()
return len(fake.cACertArgsForCall)
}
func (fake *FakeSessionContext) CACertReturns(result1 string) {
fake.CACertStub = nil
fake.cACertReturns = struct {
result1 string
}{result1}
}
func (fake *FakeSessionContext) Credentials() cmdconf.Creds {
fake.credentialsMutex.Lock()
fake.credentialsArgsForCall = append(fake.credentialsArgsForCall, struct{}{})
fake.credentialsMutex.Unlock()
if fake.CredentialsStub != nil {
return fake.CredentialsStub()
} else {
return fake.credentialsReturns.result1
}
}
func (fake *FakeSessionContext) CredentialsCallCount() int {
fake.credentialsMutex.RLock()
defer fake.credentialsMutex.RUnlock()
return len(fake.credentialsArgsForCall)
}
func (fake *FakeSessionContext) CredentialsReturns(result1 cmdconf.Creds) {
fake.CredentialsStub = nil
fake.credentialsReturns = struct {
result1 cmdconf.Creds
}{result1}
}
func (fake *FakeSessionContext) Deployment() string {
fake.deploymentMutex.Lock()
fake.deploymentArgsForCall = append(fake.deploymentArgsForCall, struct{}{})
fake.deploymentMutex.Unlock()
if fake.DeploymentStub != nil {
return fake.DeploymentStub()
} else {
return fake.deploymentReturns.result1
}
}
func (fake *FakeSessionContext) DeploymentCallCount() int {
fake.deploymentMutex.RLock()
defer fake.deploymentMutex.RUnlock()
return len(fake.deploymentArgsForCall)
}
func (fake *FakeSessionContext) DeploymentReturns(result1 string) {
fake.DeploymentStub = nil
fake.deploymentReturns = struct {
result1 string
}{result1}
}
var _ cmd.SessionContext = new(FakeSessionContext)