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

     1  // Code generated by counterfeiter. DO NOT EDIT.
     2  package v6fakes
     3  
     4  import (
     5  	"sync"
     6  
     7  	"code.cloudfoundry.org/cli/actor/pushaction"
     8  	"code.cloudfoundry.org/cli/actor/v2action"
     9  	v6 "code.cloudfoundry.org/cli/command/v6"
    10  )
    11  
    12  type FakeOriginalV2PushActor struct {
    13  	CreateAndMapDefaultApplicationRouteStub        func(string, string, v2action.Application) (pushaction.Warnings, error)
    14  	createAndMapDefaultApplicationRouteMutex       sync.RWMutex
    15  	createAndMapDefaultApplicationRouteArgsForCall []struct {
    16  		arg1 string
    17  		arg2 string
    18  		arg3 v2action.Application
    19  	}
    20  	createAndMapDefaultApplicationRouteReturns struct {
    21  		result1 pushaction.Warnings
    22  		result2 error
    23  	}
    24  	createAndMapDefaultApplicationRouteReturnsOnCall map[int]struct {
    25  		result1 pushaction.Warnings
    26  		result2 error
    27  	}
    28  	invocations      map[string][][]interface{}
    29  	invocationsMutex sync.RWMutex
    30  }
    31  
    32  func (fake *FakeOriginalV2PushActor) CreateAndMapDefaultApplicationRoute(arg1 string, arg2 string, arg3 v2action.Application) (pushaction.Warnings, error) {
    33  	fake.createAndMapDefaultApplicationRouteMutex.Lock()
    34  	ret, specificReturn := fake.createAndMapDefaultApplicationRouteReturnsOnCall[len(fake.createAndMapDefaultApplicationRouteArgsForCall)]
    35  	fake.createAndMapDefaultApplicationRouteArgsForCall = append(fake.createAndMapDefaultApplicationRouteArgsForCall, struct {
    36  		arg1 string
    37  		arg2 string
    38  		arg3 v2action.Application
    39  	}{arg1, arg2, arg3})
    40  	fake.recordInvocation("CreateAndMapDefaultApplicationRoute", []interface{}{arg1, arg2, arg3})
    41  	fake.createAndMapDefaultApplicationRouteMutex.Unlock()
    42  	if fake.CreateAndMapDefaultApplicationRouteStub != nil {
    43  		return fake.CreateAndMapDefaultApplicationRouteStub(arg1, arg2, arg3)
    44  	}
    45  	if specificReturn {
    46  		return ret.result1, ret.result2
    47  	}
    48  	fakeReturns := fake.createAndMapDefaultApplicationRouteReturns
    49  	return fakeReturns.result1, fakeReturns.result2
    50  }
    51  
    52  func (fake *FakeOriginalV2PushActor) CreateAndMapDefaultApplicationRouteCallCount() int {
    53  	fake.createAndMapDefaultApplicationRouteMutex.RLock()
    54  	defer fake.createAndMapDefaultApplicationRouteMutex.RUnlock()
    55  	return len(fake.createAndMapDefaultApplicationRouteArgsForCall)
    56  }
    57  
    58  func (fake *FakeOriginalV2PushActor) CreateAndMapDefaultApplicationRouteCalls(stub func(string, string, v2action.Application) (pushaction.Warnings, error)) {
    59  	fake.createAndMapDefaultApplicationRouteMutex.Lock()
    60  	defer fake.createAndMapDefaultApplicationRouteMutex.Unlock()
    61  	fake.CreateAndMapDefaultApplicationRouteStub = stub
    62  }
    63  
    64  func (fake *FakeOriginalV2PushActor) CreateAndMapDefaultApplicationRouteArgsForCall(i int) (string, string, v2action.Application) {
    65  	fake.createAndMapDefaultApplicationRouteMutex.RLock()
    66  	defer fake.createAndMapDefaultApplicationRouteMutex.RUnlock()
    67  	argsForCall := fake.createAndMapDefaultApplicationRouteArgsForCall[i]
    68  	return argsForCall.arg1, argsForCall.arg2, argsForCall.arg3
    69  }
    70  
    71  func (fake *FakeOriginalV2PushActor) CreateAndMapDefaultApplicationRouteReturns(result1 pushaction.Warnings, result2 error) {
    72  	fake.createAndMapDefaultApplicationRouteMutex.Lock()
    73  	defer fake.createAndMapDefaultApplicationRouteMutex.Unlock()
    74  	fake.CreateAndMapDefaultApplicationRouteStub = nil
    75  	fake.createAndMapDefaultApplicationRouteReturns = struct {
    76  		result1 pushaction.Warnings
    77  		result2 error
    78  	}{result1, result2}
    79  }
    80  
    81  func (fake *FakeOriginalV2PushActor) CreateAndMapDefaultApplicationRouteReturnsOnCall(i int, result1 pushaction.Warnings, result2 error) {
    82  	fake.createAndMapDefaultApplicationRouteMutex.Lock()
    83  	defer fake.createAndMapDefaultApplicationRouteMutex.Unlock()
    84  	fake.CreateAndMapDefaultApplicationRouteStub = nil
    85  	if fake.createAndMapDefaultApplicationRouteReturnsOnCall == nil {
    86  		fake.createAndMapDefaultApplicationRouteReturnsOnCall = make(map[int]struct {
    87  			result1 pushaction.Warnings
    88  			result2 error
    89  		})
    90  	}
    91  	fake.createAndMapDefaultApplicationRouteReturnsOnCall[i] = struct {
    92  		result1 pushaction.Warnings
    93  		result2 error
    94  	}{result1, result2}
    95  }
    96  
    97  func (fake *FakeOriginalV2PushActor) Invocations() map[string][][]interface{} {
    98  	fake.invocationsMutex.RLock()
    99  	defer fake.invocationsMutex.RUnlock()
   100  	fake.createAndMapDefaultApplicationRouteMutex.RLock()
   101  	defer fake.createAndMapDefaultApplicationRouteMutex.RUnlock()
   102  	copiedInvocations := map[string][][]interface{}{}
   103  	for key, value := range fake.invocations {
   104  		copiedInvocations[key] = value
   105  	}
   106  	return copiedInvocations
   107  }
   108  
   109  func (fake *FakeOriginalV2PushActor) recordInvocation(key string, args []interface{}) {
   110  	fake.invocationsMutex.Lock()
   111  	defer fake.invocationsMutex.Unlock()
   112  	if fake.invocations == nil {
   113  		fake.invocations = map[string][][]interface{}{}
   114  	}
   115  	if fake.invocations[key] == nil {
   116  		fake.invocations[key] = [][]interface{}{}
   117  	}
   118  	fake.invocations[key] = append(fake.invocations[key], args)
   119  }
   120  
   121  var _ v6.OriginalV2PushActor = new(FakeOriginalV2PushActor)