github.com/willmadison/cli@v6.40.1-0.20181018160101-29d5937903ff+incompatible/command/v6/v6fakes/fake_v3set_health_check_actor.go (about) 1 // Code generated by counterfeiter. DO NOT EDIT. 2 package v6fakes 3 4 import ( 5 sync "sync" 6 7 v3action "code.cloudfoundry.org/cli/actor/v3action" 8 v6 "code.cloudfoundry.org/cli/command/v6" 9 ) 10 11 type FakeV3SetHealthCheckActor struct { 12 CloudControllerAPIVersionStub func() string 13 cloudControllerAPIVersionMutex sync.RWMutex 14 cloudControllerAPIVersionArgsForCall []struct { 15 } 16 cloudControllerAPIVersionReturns struct { 17 result1 string 18 } 19 cloudControllerAPIVersionReturnsOnCall map[int]struct { 20 result1 string 21 } 22 SetApplicationProcessHealthCheckTypeByNameAndSpaceStub func(string, string, string, string, string, int) (v3action.Application, v3action.Warnings, error) 23 setApplicationProcessHealthCheckTypeByNameAndSpaceMutex sync.RWMutex 24 setApplicationProcessHealthCheckTypeByNameAndSpaceArgsForCall []struct { 25 arg1 string 26 arg2 string 27 arg3 string 28 arg4 string 29 arg5 string 30 arg6 int 31 } 32 setApplicationProcessHealthCheckTypeByNameAndSpaceReturns struct { 33 result1 v3action.Application 34 result2 v3action.Warnings 35 result3 error 36 } 37 setApplicationProcessHealthCheckTypeByNameAndSpaceReturnsOnCall map[int]struct { 38 result1 v3action.Application 39 result2 v3action.Warnings 40 result3 error 41 } 42 invocations map[string][][]interface{} 43 invocationsMutex sync.RWMutex 44 } 45 46 func (fake *FakeV3SetHealthCheckActor) CloudControllerAPIVersion() string { 47 fake.cloudControllerAPIVersionMutex.Lock() 48 ret, specificReturn := fake.cloudControllerAPIVersionReturnsOnCall[len(fake.cloudControllerAPIVersionArgsForCall)] 49 fake.cloudControllerAPIVersionArgsForCall = append(fake.cloudControllerAPIVersionArgsForCall, struct { 50 }{}) 51 fake.recordInvocation("CloudControllerAPIVersion", []interface{}{}) 52 fake.cloudControllerAPIVersionMutex.Unlock() 53 if fake.CloudControllerAPIVersionStub != nil { 54 return fake.CloudControllerAPIVersionStub() 55 } 56 if specificReturn { 57 return ret.result1 58 } 59 fakeReturns := fake.cloudControllerAPIVersionReturns 60 return fakeReturns.result1 61 } 62 63 func (fake *FakeV3SetHealthCheckActor) CloudControllerAPIVersionCallCount() int { 64 fake.cloudControllerAPIVersionMutex.RLock() 65 defer fake.cloudControllerAPIVersionMutex.RUnlock() 66 return len(fake.cloudControllerAPIVersionArgsForCall) 67 } 68 69 func (fake *FakeV3SetHealthCheckActor) CloudControllerAPIVersionCalls(stub func() string) { 70 fake.cloudControllerAPIVersionMutex.Lock() 71 defer fake.cloudControllerAPIVersionMutex.Unlock() 72 fake.CloudControllerAPIVersionStub = stub 73 } 74 75 func (fake *FakeV3SetHealthCheckActor) CloudControllerAPIVersionReturns(result1 string) { 76 fake.cloudControllerAPIVersionMutex.Lock() 77 defer fake.cloudControllerAPIVersionMutex.Unlock() 78 fake.CloudControllerAPIVersionStub = nil 79 fake.cloudControllerAPIVersionReturns = struct { 80 result1 string 81 }{result1} 82 } 83 84 func (fake *FakeV3SetHealthCheckActor) CloudControllerAPIVersionReturnsOnCall(i int, result1 string) { 85 fake.cloudControllerAPIVersionMutex.Lock() 86 defer fake.cloudControllerAPIVersionMutex.Unlock() 87 fake.CloudControllerAPIVersionStub = nil 88 if fake.cloudControllerAPIVersionReturnsOnCall == nil { 89 fake.cloudControllerAPIVersionReturnsOnCall = make(map[int]struct { 90 result1 string 91 }) 92 } 93 fake.cloudControllerAPIVersionReturnsOnCall[i] = struct { 94 result1 string 95 }{result1} 96 } 97 98 func (fake *FakeV3SetHealthCheckActor) SetApplicationProcessHealthCheckTypeByNameAndSpace(arg1 string, arg2 string, arg3 string, arg4 string, arg5 string, arg6 int) (v3action.Application, v3action.Warnings, error) { 99 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.Lock() 100 ret, specificReturn := fake.setApplicationProcessHealthCheckTypeByNameAndSpaceReturnsOnCall[len(fake.setApplicationProcessHealthCheckTypeByNameAndSpaceArgsForCall)] 101 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceArgsForCall = append(fake.setApplicationProcessHealthCheckTypeByNameAndSpaceArgsForCall, struct { 102 arg1 string 103 arg2 string 104 arg3 string 105 arg4 string 106 arg5 string 107 arg6 int 108 }{arg1, arg2, arg3, arg4, arg5, arg6}) 109 fake.recordInvocation("SetApplicationProcessHealthCheckTypeByNameAndSpace", []interface{}{arg1, arg2, arg3, arg4, arg5, arg6}) 110 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.Unlock() 111 if fake.SetApplicationProcessHealthCheckTypeByNameAndSpaceStub != nil { 112 return fake.SetApplicationProcessHealthCheckTypeByNameAndSpaceStub(arg1, arg2, arg3, arg4, arg5, arg6) 113 } 114 if specificReturn { 115 return ret.result1, ret.result2, ret.result3 116 } 117 fakeReturns := fake.setApplicationProcessHealthCheckTypeByNameAndSpaceReturns 118 return fakeReturns.result1, fakeReturns.result2, fakeReturns.result3 119 } 120 121 func (fake *FakeV3SetHealthCheckActor) SetApplicationProcessHealthCheckTypeByNameAndSpaceCallCount() int { 122 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.RLock() 123 defer fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.RUnlock() 124 return len(fake.setApplicationProcessHealthCheckTypeByNameAndSpaceArgsForCall) 125 } 126 127 func (fake *FakeV3SetHealthCheckActor) SetApplicationProcessHealthCheckTypeByNameAndSpaceCalls(stub func(string, string, string, string, string, int) (v3action.Application, v3action.Warnings, error)) { 128 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.Lock() 129 defer fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.Unlock() 130 fake.SetApplicationProcessHealthCheckTypeByNameAndSpaceStub = stub 131 } 132 133 func (fake *FakeV3SetHealthCheckActor) SetApplicationProcessHealthCheckTypeByNameAndSpaceArgsForCall(i int) (string, string, string, string, string, int) { 134 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.RLock() 135 defer fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.RUnlock() 136 argsForCall := fake.setApplicationProcessHealthCheckTypeByNameAndSpaceArgsForCall[i] 137 return argsForCall.arg1, argsForCall.arg2, argsForCall.arg3, argsForCall.arg4, argsForCall.arg5, argsForCall.arg6 138 } 139 140 func (fake *FakeV3SetHealthCheckActor) SetApplicationProcessHealthCheckTypeByNameAndSpaceReturns(result1 v3action.Application, result2 v3action.Warnings, result3 error) { 141 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.Lock() 142 defer fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.Unlock() 143 fake.SetApplicationProcessHealthCheckTypeByNameAndSpaceStub = nil 144 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceReturns = struct { 145 result1 v3action.Application 146 result2 v3action.Warnings 147 result3 error 148 }{result1, result2, result3} 149 } 150 151 func (fake *FakeV3SetHealthCheckActor) SetApplicationProcessHealthCheckTypeByNameAndSpaceReturnsOnCall(i int, result1 v3action.Application, result2 v3action.Warnings, result3 error) { 152 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.Lock() 153 defer fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.Unlock() 154 fake.SetApplicationProcessHealthCheckTypeByNameAndSpaceStub = nil 155 if fake.setApplicationProcessHealthCheckTypeByNameAndSpaceReturnsOnCall == nil { 156 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceReturnsOnCall = make(map[int]struct { 157 result1 v3action.Application 158 result2 v3action.Warnings 159 result3 error 160 }) 161 } 162 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceReturnsOnCall[i] = struct { 163 result1 v3action.Application 164 result2 v3action.Warnings 165 result3 error 166 }{result1, result2, result3} 167 } 168 169 func (fake *FakeV3SetHealthCheckActor) Invocations() map[string][][]interface{} { 170 fake.invocationsMutex.RLock() 171 defer fake.invocationsMutex.RUnlock() 172 fake.cloudControllerAPIVersionMutex.RLock() 173 defer fake.cloudControllerAPIVersionMutex.RUnlock() 174 fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.RLock() 175 defer fake.setApplicationProcessHealthCheckTypeByNameAndSpaceMutex.RUnlock() 176 copiedInvocations := map[string][][]interface{}{} 177 for key, value := range fake.invocations { 178 copiedInvocations[key] = value 179 } 180 return copiedInvocations 181 } 182 183 func (fake *FakeV3SetHealthCheckActor) recordInvocation(key string, args []interface{}) { 184 fake.invocationsMutex.Lock() 185 defer fake.invocationsMutex.Unlock() 186 if fake.invocations == nil { 187 fake.invocations = map[string][][]interface{}{} 188 } 189 if fake.invocations[key] == nil { 190 fake.invocations[key] = [][]interface{}{} 191 } 192 fake.invocations[key] = append(fake.invocations[key], args) 193 } 194 195 var _ v6.V3SetHealthCheckActor = new(FakeV3SetHealthCheckActor)