github.com/mook-as/cf-cli@v7.0.0-beta.28.0.20200120190804-b91c115fae48+incompatible/command/v6/v6fakes/fake_delete_buildpack_actor.go (about)

     1  // Code generated by counterfeiter. DO NOT EDIT.
     2  package v6fakes
     3  
     4  import (
     5  	"sync"
     6  
     7  	v6 "code.cloudfoundry.org/cli/command/v6"
     8  )
     9  
    10  type FakeDeleteBuildpackActor struct {
    11  	CloudControllerAPIVersionStub        func() string
    12  	cloudControllerAPIVersionMutex       sync.RWMutex
    13  	cloudControllerAPIVersionArgsForCall []struct {
    14  	}
    15  	cloudControllerAPIVersionReturns struct {
    16  		result1 string
    17  	}
    18  	cloudControllerAPIVersionReturnsOnCall map[int]struct {
    19  		result1 string
    20  	}
    21  	invocations      map[string][][]interface{}
    22  	invocationsMutex sync.RWMutex
    23  }
    24  
    25  func (fake *FakeDeleteBuildpackActor) CloudControllerAPIVersion() string {
    26  	fake.cloudControllerAPIVersionMutex.Lock()
    27  	ret, specificReturn := fake.cloudControllerAPIVersionReturnsOnCall[len(fake.cloudControllerAPIVersionArgsForCall)]
    28  	fake.cloudControllerAPIVersionArgsForCall = append(fake.cloudControllerAPIVersionArgsForCall, struct {
    29  	}{})
    30  	fake.recordInvocation("CloudControllerAPIVersion", []interface{}{})
    31  	fake.cloudControllerAPIVersionMutex.Unlock()
    32  	if fake.CloudControllerAPIVersionStub != nil {
    33  		return fake.CloudControllerAPIVersionStub()
    34  	}
    35  	if specificReturn {
    36  		return ret.result1
    37  	}
    38  	fakeReturns := fake.cloudControllerAPIVersionReturns
    39  	return fakeReturns.result1
    40  }
    41  
    42  func (fake *FakeDeleteBuildpackActor) CloudControllerAPIVersionCallCount() int {
    43  	fake.cloudControllerAPIVersionMutex.RLock()
    44  	defer fake.cloudControllerAPIVersionMutex.RUnlock()
    45  	return len(fake.cloudControllerAPIVersionArgsForCall)
    46  }
    47  
    48  func (fake *FakeDeleteBuildpackActor) CloudControllerAPIVersionCalls(stub func() string) {
    49  	fake.cloudControllerAPIVersionMutex.Lock()
    50  	defer fake.cloudControllerAPIVersionMutex.Unlock()
    51  	fake.CloudControllerAPIVersionStub = stub
    52  }
    53  
    54  func (fake *FakeDeleteBuildpackActor) CloudControllerAPIVersionReturns(result1 string) {
    55  	fake.cloudControllerAPIVersionMutex.Lock()
    56  	defer fake.cloudControllerAPIVersionMutex.Unlock()
    57  	fake.CloudControllerAPIVersionStub = nil
    58  	fake.cloudControllerAPIVersionReturns = struct {
    59  		result1 string
    60  	}{result1}
    61  }
    62  
    63  func (fake *FakeDeleteBuildpackActor) CloudControllerAPIVersionReturnsOnCall(i int, result1 string) {
    64  	fake.cloudControllerAPIVersionMutex.Lock()
    65  	defer fake.cloudControllerAPIVersionMutex.Unlock()
    66  	fake.CloudControllerAPIVersionStub = nil
    67  	if fake.cloudControllerAPIVersionReturnsOnCall == nil {
    68  		fake.cloudControllerAPIVersionReturnsOnCall = make(map[int]struct {
    69  			result1 string
    70  		})
    71  	}
    72  	fake.cloudControllerAPIVersionReturnsOnCall[i] = struct {
    73  		result1 string
    74  	}{result1}
    75  }
    76  
    77  func (fake *FakeDeleteBuildpackActor) Invocations() map[string][][]interface{} {
    78  	fake.invocationsMutex.RLock()
    79  	defer fake.invocationsMutex.RUnlock()
    80  	fake.cloudControllerAPIVersionMutex.RLock()
    81  	defer fake.cloudControllerAPIVersionMutex.RUnlock()
    82  	copiedInvocations := map[string][][]interface{}{}
    83  	for key, value := range fake.invocations {
    84  		copiedInvocations[key] = value
    85  	}
    86  	return copiedInvocations
    87  }
    88  
    89  func (fake *FakeDeleteBuildpackActor) recordInvocation(key string, args []interface{}) {
    90  	fake.invocationsMutex.Lock()
    91  	defer fake.invocationsMutex.Unlock()
    92  	if fake.invocations == nil {
    93  		fake.invocations = map[string][][]interface{}{}
    94  	}
    95  	if fake.invocations[key] == nil {
    96  		fake.invocations[key] = [][]interface{}{}
    97  	}
    98  	fake.invocations[key] = append(fake.invocations[key], args)
    99  }
   100  
   101  var _ v6.DeleteBuildpackActor = new(FakeDeleteBuildpackActor)