1 Star 0 Fork 0

陈文甲/fabric

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
support.go 39.31 KB
一键复制 编辑 原始数据 按行查看 历史
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190
// Code generated by counterfeiter. DO NOT EDIT.
package mocks
import (
"sync"
"github.com/hyperledger/fabric/common/channelconfig"
"github.com/hyperledger/fabric/core/common/ccprovider"
endorser_test "github.com/hyperledger/fabric/core/endorser"
"github.com/hyperledger/fabric/core/ledger"
"github.com/hyperledger/fabric/protos/common"
pb "github.com/hyperledger/fabric/protos/peer"
"golang.org/x/net/context"
)
type Support struct {
SignStub func(message []byte) ([]byte, error)
signMutex sync.RWMutex
signArgsForCall []struct {
message []byte
}
signReturns struct {
result1 []byte
result2 error
}
signReturnsOnCall map[int]struct {
result1 []byte
result2 error
}
SerializeStub func() ([]byte, error)
serializeMutex sync.RWMutex
serializeArgsForCall []struct{}
serializeReturns struct {
result1 []byte
result2 error
}
serializeReturnsOnCall map[int]struct {
result1 []byte
result2 error
}
IsSysCCAndNotInvokableExternalStub func(name string) bool
isSysCCAndNotInvokableExternalMutex sync.RWMutex
isSysCCAndNotInvokableExternalArgsForCall []struct {
name string
}
isSysCCAndNotInvokableExternalReturns struct {
result1 bool
}
isSysCCAndNotInvokableExternalReturnsOnCall map[int]struct {
result1 bool
}
GetTxSimulatorStub func(ledgername string, txid string) (ledger.TxSimulator, error)
getTxSimulatorMutex sync.RWMutex
getTxSimulatorArgsForCall []struct {
ledgername string
txid string
}
getTxSimulatorReturns struct {
result1 ledger.TxSimulator
result2 error
}
getTxSimulatorReturnsOnCall map[int]struct {
result1 ledger.TxSimulator
result2 error
}
GetHistoryQueryExecutorStub func(ledgername string) (ledger.HistoryQueryExecutor, error)
getHistoryQueryExecutorMutex sync.RWMutex
getHistoryQueryExecutorArgsForCall []struct {
ledgername string
}
getHistoryQueryExecutorReturns struct {
result1 ledger.HistoryQueryExecutor
result2 error
}
getHistoryQueryExecutorReturnsOnCall map[int]struct {
result1 ledger.HistoryQueryExecutor
result2 error
}
GetTransactionByIDStub func(chid, txID string) (*pb.ProcessedTransaction, error)
getTransactionByIDMutex sync.RWMutex
getTransactionByIDArgsForCall []struct {
chid string
txID string
}
getTransactionByIDReturns struct {
result1 *pb.ProcessedTransaction
result2 error
}
getTransactionByIDReturnsOnCall map[int]struct {
result1 *pb.ProcessedTransaction
result2 error
}
IsSysCCStub func(name string) bool
isSysCCMutex sync.RWMutex
isSysCCArgsForCall []struct {
name string
}
isSysCCReturns struct {
result1 bool
}
isSysCCReturnsOnCall map[int]struct {
result1 bool
}
ExecuteStub func(ctxt context.Context, cid, name, version, txid string, syscc bool, signedProp *pb.SignedProposal, prop *pb.Proposal, spec ccprovider.ChaincodeSpecGetter) (*pb.Response, *pb.ChaincodeEvent, error)
executeMutex sync.RWMutex
executeArgsForCall []struct {
ctxt context.Context
cid string
name string
version string
txid string
syscc bool
signedProp *pb.SignedProposal
prop *pb.Proposal
spec ccprovider.ChaincodeSpecGetter
}
executeReturns struct {
result1 *pb.Response
result2 *pb.ChaincodeEvent
result3 error
}
executeReturnsOnCall map[int]struct {
result1 *pb.Response
result2 *pb.ChaincodeEvent
result3 error
}
GetChaincodeDefinitionStub func(ctx context.Context, chainID string, txid string, signedProp *pb.SignedProposal, prop *pb.Proposal, chaincodeID string, txsim ledger.TxSimulator) (ccprovider.ChaincodeDefinition, error)
getChaincodeDefinitionMutex sync.RWMutex
getChaincodeDefinitionArgsForCall []struct {
ctx context.Context
chainID string
txid string
signedProp *pb.SignedProposal
prop *pb.Proposal
chaincodeID string
txsim ledger.TxSimulator
}
getChaincodeDefinitionReturns struct {
result1 ccprovider.ChaincodeDefinition
result2 error
}
getChaincodeDefinitionReturnsOnCall map[int]struct {
result1 ccprovider.ChaincodeDefinition
result2 error
}
CheckACLStub func(signedProp *pb.SignedProposal, chdr *common.ChannelHeader, shdr *common.SignatureHeader, hdrext *pb.ChaincodeHeaderExtension) error
checkACLMutex sync.RWMutex
checkACLArgsForCall []struct {
signedProp *pb.SignedProposal
chdr *common.ChannelHeader
shdr *common.SignatureHeader
hdrext *pb.ChaincodeHeaderExtension
}
checkACLReturns struct {
result1 error
}
checkACLReturnsOnCall map[int]struct {
result1 error
}
IsJavaCCStub func(buf []byte) (bool, error)
isJavaCCMutex sync.RWMutex
isJavaCCArgsForCall []struct {
buf []byte
}
isJavaCCReturns struct {
result1 bool
result2 error
}
isJavaCCReturnsOnCall map[int]struct {
result1 bool
result2 error
}
CheckInstantiationPolicyStub func(name, version string, cd ccprovider.ChaincodeDefinition) error
checkInstantiationPolicyMutex sync.RWMutex
checkInstantiationPolicyArgsForCall []struct {
name string
version string
cd ccprovider.ChaincodeDefinition
}
checkInstantiationPolicyReturns struct {
result1 error
}
checkInstantiationPolicyReturnsOnCall map[int]struct {
result1 error
}
GetChaincodeDeploymentSpecFSStub func(cds *pb.ChaincodeDeploymentSpec) (*pb.ChaincodeDeploymentSpec, error)
getChaincodeDeploymentSpecFSMutex sync.RWMutex
getChaincodeDeploymentSpecFSArgsForCall []struct {
cds *pb.ChaincodeDeploymentSpec
}
getChaincodeDeploymentSpecFSReturns struct {
result1 *pb.ChaincodeDeploymentSpec
result2 error
}
getChaincodeDeploymentSpecFSReturnsOnCall map[int]struct {
result1 *pb.ChaincodeDeploymentSpec
result2 error
}
GetApplicationConfigStub func(cid string) (channelconfig.Application, bool)
getApplicationConfigMutex sync.RWMutex
getApplicationConfigArgsForCall []struct {
cid string
}
getApplicationConfigReturns struct {
result1 channelconfig.Application
result2 bool
}
getApplicationConfigReturnsOnCall map[int]struct {
result1 channelconfig.Application
result2 bool
}
NewQueryCreatorStub func(channel string) (endorser_test.QueryCreator, error)
newQueryCreatorMutex sync.RWMutex
newQueryCreatorArgsForCall []struct {
channel string
}
newQueryCreatorReturns struct {
result1 endorser_test.QueryCreator
result2 error
}
newQueryCreatorReturnsOnCall map[int]struct {
result1 endorser_test.QueryCreator
result2 error
}
EndorseWithPluginStub func(ctx endorser_test.Context) (*pb.ProposalResponse, error)
endorseWithPluginMutex sync.RWMutex
endorseWithPluginArgsForCall []struct {
ctx endorser_test.Context
}
endorseWithPluginReturns struct {
result1 *pb.ProposalResponse
result2 error
}
endorseWithPluginReturnsOnCall map[int]struct {
result1 *pb.ProposalResponse
result2 error
}
GetLedgerHeightStub func(channelID string) (uint64, error)
getLedgerHeightMutex sync.RWMutex
getLedgerHeightArgsForCall []struct {
channelID string
}
getLedgerHeightReturns struct {
result1 uint64
result2 error
}
getLedgerHeightReturnsOnCall map[int]struct {
result1 uint64
result2 error
}
invocations map[string][][]interface{}
invocationsMutex sync.RWMutex
}
func (fake *Support) Sign(message []byte) ([]byte, error) {
var messageCopy []byte
if message != nil {
messageCopy = make([]byte, len(message))
copy(messageCopy, message)
}
fake.signMutex.Lock()
ret, specificReturn := fake.signReturnsOnCall[len(fake.signArgsForCall)]
fake.signArgsForCall = append(fake.signArgsForCall, struct {
message []byte
}{messageCopy})
fake.recordInvocation("Sign", []interface{}{messageCopy})
fake.signMutex.Unlock()
if fake.SignStub != nil {
return fake.SignStub(message)
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.signReturns.result1, fake.signReturns.result2
}
func (fake *Support) SignCallCount() int {
fake.signMutex.RLock()
defer fake.signMutex.RUnlock()
return len(fake.signArgsForCall)
}
func (fake *Support) SignArgsForCall(i int) []byte {
fake.signMutex.RLock()
defer fake.signMutex.RUnlock()
return fake.signArgsForCall[i].message
}
func (fake *Support) SignReturns(result1 []byte, result2 error) {
fake.SignStub = nil
fake.signReturns = struct {
result1 []byte
result2 error
}{result1, result2}
}
func (fake *Support) SignReturnsOnCall(i int, result1 []byte, result2 error) {
fake.SignStub = nil
if fake.signReturnsOnCall == nil {
fake.signReturnsOnCall = make(map[int]struct {
result1 []byte
result2 error
})
}
fake.signReturnsOnCall[i] = struct {
result1 []byte
result2 error
}{result1, result2}
}
func (fake *Support) Serialize() ([]byte, error) {
fake.serializeMutex.Lock()
ret, specificReturn := fake.serializeReturnsOnCall[len(fake.serializeArgsForCall)]
fake.serializeArgsForCall = append(fake.serializeArgsForCall, struct{}{})
fake.recordInvocation("Serialize", []interface{}{})
fake.serializeMutex.Unlock()
if fake.SerializeStub != nil {
return fake.SerializeStub()
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.serializeReturns.result1, fake.serializeReturns.result2
}
func (fake *Support) SerializeCallCount() int {
fake.serializeMutex.RLock()
defer fake.serializeMutex.RUnlock()
return len(fake.serializeArgsForCall)
}
func (fake *Support) SerializeReturns(result1 []byte, result2 error) {
fake.SerializeStub = nil
fake.serializeReturns = struct {
result1 []byte
result2 error
}{result1, result2}
}
func (fake *Support) SerializeReturnsOnCall(i int, result1 []byte, result2 error) {
fake.SerializeStub = nil
if fake.serializeReturnsOnCall == nil {
fake.serializeReturnsOnCall = make(map[int]struct {
result1 []byte
result2 error
})
}
fake.serializeReturnsOnCall[i] = struct {
result1 []byte
result2 error
}{result1, result2}
}
func (fake *Support) IsSysCCAndNotInvokableExternal(name string) bool {
fake.isSysCCAndNotInvokableExternalMutex.Lock()
ret, specificReturn := fake.isSysCCAndNotInvokableExternalReturnsOnCall[len(fake.isSysCCAndNotInvokableExternalArgsForCall)]
fake.isSysCCAndNotInvokableExternalArgsForCall = append(fake.isSysCCAndNotInvokableExternalArgsForCall, struct {
name string
}{name})
fake.recordInvocation("IsSysCCAndNotInvokableExternal", []interface{}{name})
fake.isSysCCAndNotInvokableExternalMutex.Unlock()
if fake.IsSysCCAndNotInvokableExternalStub != nil {
return fake.IsSysCCAndNotInvokableExternalStub(name)
}
if specificReturn {
return ret.result1
}
return fake.isSysCCAndNotInvokableExternalReturns.result1
}
func (fake *Support) IsSysCCAndNotInvokableExternalCallCount() int {
fake.isSysCCAndNotInvokableExternalMutex.RLock()
defer fake.isSysCCAndNotInvokableExternalMutex.RUnlock()
return len(fake.isSysCCAndNotInvokableExternalArgsForCall)
}
func (fake *Support) IsSysCCAndNotInvokableExternalArgsForCall(i int) string {
fake.isSysCCAndNotInvokableExternalMutex.RLock()
defer fake.isSysCCAndNotInvokableExternalMutex.RUnlock()
return fake.isSysCCAndNotInvokableExternalArgsForCall[i].name
}
func (fake *Support) IsSysCCAndNotInvokableExternalReturns(result1 bool) {
fake.IsSysCCAndNotInvokableExternalStub = nil
fake.isSysCCAndNotInvokableExternalReturns = struct {
result1 bool
}{result1}
}
func (fake *Support) IsSysCCAndNotInvokableExternalReturnsOnCall(i int, result1 bool) {
fake.IsSysCCAndNotInvokableExternalStub = nil
if fake.isSysCCAndNotInvokableExternalReturnsOnCall == nil {
fake.isSysCCAndNotInvokableExternalReturnsOnCall = make(map[int]struct {
result1 bool
})
}
fake.isSysCCAndNotInvokableExternalReturnsOnCall[i] = struct {
result1 bool
}{result1}
}
func (fake *Support) GetTxSimulator(ledgername string, txid string) (ledger.TxSimulator, error) {
fake.getTxSimulatorMutex.Lock()
ret, specificReturn := fake.getTxSimulatorReturnsOnCall[len(fake.getTxSimulatorArgsForCall)]
fake.getTxSimulatorArgsForCall = append(fake.getTxSimulatorArgsForCall, struct {
ledgername string
txid string
}{ledgername, txid})
fake.recordInvocation("GetTxSimulator", []interface{}{ledgername, txid})
fake.getTxSimulatorMutex.Unlock()
if fake.GetTxSimulatorStub != nil {
return fake.GetTxSimulatorStub(ledgername, txid)
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.getTxSimulatorReturns.result1, fake.getTxSimulatorReturns.result2
}
func (fake *Support) GetTxSimulatorCallCount() int {
fake.getTxSimulatorMutex.RLock()
defer fake.getTxSimulatorMutex.RUnlock()
return len(fake.getTxSimulatorArgsForCall)
}
func (fake *Support) GetTxSimulatorArgsForCall(i int) (string, string) {
fake.getTxSimulatorMutex.RLock()
defer fake.getTxSimulatorMutex.RUnlock()
return fake.getTxSimulatorArgsForCall[i].ledgername, fake.getTxSimulatorArgsForCall[i].txid
}
func (fake *Support) GetTxSimulatorReturns(result1 ledger.TxSimulator, result2 error) {
fake.GetTxSimulatorStub = nil
fake.getTxSimulatorReturns = struct {
result1 ledger.TxSimulator
result2 error
}{result1, result2}
}
func (fake *Support) GetTxSimulatorReturnsOnCall(i int, result1 ledger.TxSimulator, result2 error) {
fake.GetTxSimulatorStub = nil
if fake.getTxSimulatorReturnsOnCall == nil {
fake.getTxSimulatorReturnsOnCall = make(map[int]struct {
result1 ledger.TxSimulator
result2 error
})
}
fake.getTxSimulatorReturnsOnCall[i] = struct {
result1 ledger.TxSimulator
result2 error
}{result1, result2}
}
func (fake *Support) GetHistoryQueryExecutor(ledgername string) (ledger.HistoryQueryExecutor, error) {
fake.getHistoryQueryExecutorMutex.Lock()
ret, specificReturn := fake.getHistoryQueryExecutorReturnsOnCall[len(fake.getHistoryQueryExecutorArgsForCall)]
fake.getHistoryQueryExecutorArgsForCall = append(fake.getHistoryQueryExecutorArgsForCall, struct {
ledgername string
}{ledgername})
fake.recordInvocation("GetHistoryQueryExecutor", []interface{}{ledgername})
fake.getHistoryQueryExecutorMutex.Unlock()
if fake.GetHistoryQueryExecutorStub != nil {
return fake.GetHistoryQueryExecutorStub(ledgername)
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.getHistoryQueryExecutorReturns.result1, fake.getHistoryQueryExecutorReturns.result2
}
func (fake *Support) GetHistoryQueryExecutorCallCount() int {
fake.getHistoryQueryExecutorMutex.RLock()
defer fake.getHistoryQueryExecutorMutex.RUnlock()
return len(fake.getHistoryQueryExecutorArgsForCall)
}
func (fake *Support) GetHistoryQueryExecutorArgsForCall(i int) string {
fake.getHistoryQueryExecutorMutex.RLock()
defer fake.getHistoryQueryExecutorMutex.RUnlock()
return fake.getHistoryQueryExecutorArgsForCall[i].ledgername
}
func (fake *Support) GetHistoryQueryExecutorReturns(result1 ledger.HistoryQueryExecutor, result2 error) {
fake.GetHistoryQueryExecutorStub = nil
fake.getHistoryQueryExecutorReturns = struct {
result1 ledger.HistoryQueryExecutor
result2 error
}{result1, result2}
}
func (fake *Support) GetHistoryQueryExecutorReturnsOnCall(i int, result1 ledger.HistoryQueryExecutor, result2 error) {
fake.GetHistoryQueryExecutorStub = nil
if fake.getHistoryQueryExecutorReturnsOnCall == nil {
fake.getHistoryQueryExecutorReturnsOnCall = make(map[int]struct {
result1 ledger.HistoryQueryExecutor
result2 error
})
}
fake.getHistoryQueryExecutorReturnsOnCall[i] = struct {
result1 ledger.HistoryQueryExecutor
result2 error
}{result1, result2}
}
func (fake *Support) GetTransactionByID(chid string, txID string) (*pb.ProcessedTransaction, error) {
fake.getTransactionByIDMutex.Lock()
ret, specificReturn := fake.getTransactionByIDReturnsOnCall[len(fake.getTransactionByIDArgsForCall)]
fake.getTransactionByIDArgsForCall = append(fake.getTransactionByIDArgsForCall, struct {
chid string
txID string
}{chid, txID})
fake.recordInvocation("GetTransactionByID", []interface{}{chid, txID})
fake.getTransactionByIDMutex.Unlock()
if fake.GetTransactionByIDStub != nil {
return fake.GetTransactionByIDStub(chid, txID)
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.getTransactionByIDReturns.result1, fake.getTransactionByIDReturns.result2
}
func (fake *Support) GetTransactionByIDCallCount() int {
fake.getTransactionByIDMutex.RLock()
defer fake.getTransactionByIDMutex.RUnlock()
return len(fake.getTransactionByIDArgsForCall)
}
func (fake *Support) GetTransactionByIDArgsForCall(i int) (string, string) {
fake.getTransactionByIDMutex.RLock()
defer fake.getTransactionByIDMutex.RUnlock()
return fake.getTransactionByIDArgsForCall[i].chid, fake.getTransactionByIDArgsForCall[i].txID
}
func (fake *Support) GetTransactionByIDReturns(result1 *pb.ProcessedTransaction, result2 error) {
fake.GetTransactionByIDStub = nil
fake.getTransactionByIDReturns = struct {
result1 *pb.ProcessedTransaction
result2 error
}{result1, result2}
}
func (fake *Support) GetTransactionByIDReturnsOnCall(i int, result1 *pb.ProcessedTransaction, result2 error) {
fake.GetTransactionByIDStub = nil
if fake.getTransactionByIDReturnsOnCall == nil {
fake.getTransactionByIDReturnsOnCall = make(map[int]struct {
result1 *pb.ProcessedTransaction
result2 error
})
}
fake.getTransactionByIDReturnsOnCall[i] = struct {
result1 *pb.ProcessedTransaction
result2 error
}{result1, result2}
}
func (fake *Support) IsSysCC(name string) bool {
fake.isSysCCMutex.Lock()
ret, specificReturn := fake.isSysCCReturnsOnCall[len(fake.isSysCCArgsForCall)]
fake.isSysCCArgsForCall = append(fake.isSysCCArgsForCall, struct {
name string
}{name})
fake.recordInvocation("IsSysCC", []interface{}{name})
fake.isSysCCMutex.Unlock()
if fake.IsSysCCStub != nil {
return fake.IsSysCCStub(name)
}
if specificReturn {
return ret.result1
}
return fake.isSysCCReturns.result1
}
func (fake *Support) IsSysCCCallCount() int {
fake.isSysCCMutex.RLock()
defer fake.isSysCCMutex.RUnlock()
return len(fake.isSysCCArgsForCall)
}
func (fake *Support) IsSysCCArgsForCall(i int) string {
fake.isSysCCMutex.RLock()
defer fake.isSysCCMutex.RUnlock()
return fake.isSysCCArgsForCall[i].name
}
func (fake *Support) IsSysCCReturns(result1 bool) {
fake.IsSysCCStub = nil
fake.isSysCCReturns = struct {
result1 bool
}{result1}
}
func (fake *Support) IsSysCCReturnsOnCall(i int, result1 bool) {
fake.IsSysCCStub = nil
if fake.isSysCCReturnsOnCall == nil {
fake.isSysCCReturnsOnCall = make(map[int]struct {
result1 bool
})
}
fake.isSysCCReturnsOnCall[i] = struct {
result1 bool
}{result1}
}
func (fake *Support) Execute(ctxt context.Context, cid string, name string, version string, txid string, syscc bool, signedProp *pb.SignedProposal, prop *pb.Proposal, spec ccprovider.ChaincodeSpecGetter) (*pb.Response, *pb.ChaincodeEvent, error) {
fake.executeMutex.Lock()
ret, specificReturn := fake.executeReturnsOnCall[len(fake.executeArgsForCall)]
fake.executeArgsForCall = append(fake.executeArgsForCall, struct {
ctxt context.Context
cid string
name string
version string
txid string
syscc bool
signedProp *pb.SignedProposal
prop *pb.Proposal
spec ccprovider.ChaincodeSpecGetter
}{ctxt, cid, name, version, txid, syscc, signedProp, prop, spec})
fake.recordInvocation("Execute", []interface{}{ctxt, cid, name, version, txid, syscc, signedProp, prop, spec})
fake.executeMutex.Unlock()
if fake.ExecuteStub != nil {
return fake.ExecuteStub(ctxt, cid, name, version, txid, syscc, signedProp, prop, spec)
}
if specificReturn {
return ret.result1, ret.result2, ret.result3
}
return fake.executeReturns.result1, fake.executeReturns.result2, fake.executeReturns.result3
}
func (fake *Support) ExecuteCallCount() int {
fake.executeMutex.RLock()
defer fake.executeMutex.RUnlock()
return len(fake.executeArgsForCall)
}
func (fake *Support) ExecuteArgsForCall(i int) (context.Context, string, string, string, string, bool, *pb.SignedProposal, *pb.Proposal, ccprovider.ChaincodeSpecGetter) {
fake.executeMutex.RLock()
defer fake.executeMutex.RUnlock()
return fake.executeArgsForCall[i].ctxt, fake.executeArgsForCall[i].cid, fake.executeArgsForCall[i].name, fake.executeArgsForCall[i].version, fake.executeArgsForCall[i].txid, fake.executeArgsForCall[i].syscc, fake.executeArgsForCall[i].signedProp, fake.executeArgsForCall[i].prop, fake.executeArgsForCall[i].spec
}
func (fake *Support) ExecuteReturns(result1 *pb.Response, result2 *pb.ChaincodeEvent, result3 error) {
fake.ExecuteStub = nil
fake.executeReturns = struct {
result1 *pb.Response
result2 *pb.ChaincodeEvent
result3 error
}{result1, result2, result3}
}
func (fake *Support) ExecuteReturnsOnCall(i int, result1 *pb.Response, result2 *pb.ChaincodeEvent, result3 error) {
fake.ExecuteStub = nil
if fake.executeReturnsOnCall == nil {
fake.executeReturnsOnCall = make(map[int]struct {
result1 *pb.Response
result2 *pb.ChaincodeEvent
result3 error
})
}
fake.executeReturnsOnCall[i] = struct {
result1 *pb.Response
result2 *pb.ChaincodeEvent
result3 error
}{result1, result2, result3}
}
func (fake *Support) GetChaincodeDefinition(ctx context.Context, chainID string, txid string, signedProp *pb.SignedProposal, prop *pb.Proposal, chaincodeID string, txsim ledger.TxSimulator) (ccprovider.ChaincodeDefinition, error) {
fake.getChaincodeDefinitionMutex.Lock()
ret, specificReturn := fake.getChaincodeDefinitionReturnsOnCall[len(fake.getChaincodeDefinitionArgsForCall)]
fake.getChaincodeDefinitionArgsForCall = append(fake.getChaincodeDefinitionArgsForCall, struct {
ctx context.Context
chainID string
txid string
signedProp *pb.SignedProposal
prop *pb.Proposal
chaincodeID string
txsim ledger.TxSimulator
}{ctx, chainID, txid, signedProp, prop, chaincodeID, txsim})
fake.recordInvocation("GetChaincodeDefinition", []interface{}{ctx, chainID, txid, signedProp, prop, chaincodeID, txsim})
fake.getChaincodeDefinitionMutex.Unlock()
if fake.GetChaincodeDefinitionStub != nil {
return fake.GetChaincodeDefinitionStub(ctx, chainID, txid, signedProp, prop, chaincodeID, txsim)
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.getChaincodeDefinitionReturns.result1, fake.getChaincodeDefinitionReturns.result2
}
func (fake *Support) GetChaincodeDefinitionCallCount() int {
fake.getChaincodeDefinitionMutex.RLock()
defer fake.getChaincodeDefinitionMutex.RUnlock()
return len(fake.getChaincodeDefinitionArgsForCall)
}
func (fake *Support) GetChaincodeDefinitionArgsForCall(i int) (context.Context, string, string, *pb.SignedProposal, *pb.Proposal, string, ledger.TxSimulator) {
fake.getChaincodeDefinitionMutex.RLock()
defer fake.getChaincodeDefinitionMutex.RUnlock()
return fake.getChaincodeDefinitionArgsForCall[i].ctx, fake.getChaincodeDefinitionArgsForCall[i].chainID, fake.getChaincodeDefinitionArgsForCall[i].txid, fake.getChaincodeDefinitionArgsForCall[i].signedProp, fake.getChaincodeDefinitionArgsForCall[i].prop, fake.getChaincodeDefinitionArgsForCall[i].chaincodeID, fake.getChaincodeDefinitionArgsForCall[i].txsim
}
func (fake *Support) GetChaincodeDefinitionReturns(result1 ccprovider.ChaincodeDefinition, result2 error) {
fake.GetChaincodeDefinitionStub = nil
fake.getChaincodeDefinitionReturns = struct {
result1 ccprovider.ChaincodeDefinition
result2 error
}{result1, result2}
}
func (fake *Support) GetChaincodeDefinitionReturnsOnCall(i int, result1 ccprovider.ChaincodeDefinition, result2 error) {
fake.GetChaincodeDefinitionStub = nil
if fake.getChaincodeDefinitionReturnsOnCall == nil {
fake.getChaincodeDefinitionReturnsOnCall = make(map[int]struct {
result1 ccprovider.ChaincodeDefinition
result2 error
})
}
fake.getChaincodeDefinitionReturnsOnCall[i] = struct {
result1 ccprovider.ChaincodeDefinition
result2 error
}{result1, result2}
}
func (fake *Support) CheckACL(signedProp *pb.SignedProposal, chdr *common.ChannelHeader, shdr *common.SignatureHeader, hdrext *pb.ChaincodeHeaderExtension) error {
fake.checkACLMutex.Lock()
ret, specificReturn := fake.checkACLReturnsOnCall[len(fake.checkACLArgsForCall)]
fake.checkACLArgsForCall = append(fake.checkACLArgsForCall, struct {
signedProp *pb.SignedProposal
chdr *common.ChannelHeader
shdr *common.SignatureHeader
hdrext *pb.ChaincodeHeaderExtension
}{signedProp, chdr, shdr, hdrext})
fake.recordInvocation("CheckACL", []interface{}{signedProp, chdr, shdr, hdrext})
fake.checkACLMutex.Unlock()
if fake.CheckACLStub != nil {
return fake.CheckACLStub(signedProp, chdr, shdr, hdrext)
}
if specificReturn {
return ret.result1
}
return fake.checkACLReturns.result1
}
func (fake *Support) CheckACLCallCount() int {
fake.checkACLMutex.RLock()
defer fake.checkACLMutex.RUnlock()
return len(fake.checkACLArgsForCall)
}
func (fake *Support) CheckACLArgsForCall(i int) (*pb.SignedProposal, *common.ChannelHeader, *common.SignatureHeader, *pb.ChaincodeHeaderExtension) {
fake.checkACLMutex.RLock()
defer fake.checkACLMutex.RUnlock()
return fake.checkACLArgsForCall[i].signedProp, fake.checkACLArgsForCall[i].chdr, fake.checkACLArgsForCall[i].shdr, fake.checkACLArgsForCall[i].hdrext
}
func (fake *Support) CheckACLReturns(result1 error) {
fake.CheckACLStub = nil
fake.checkACLReturns = struct {
result1 error
}{result1}
}
func (fake *Support) CheckACLReturnsOnCall(i int, result1 error) {
fake.CheckACLStub = nil
if fake.checkACLReturnsOnCall == nil {
fake.checkACLReturnsOnCall = make(map[int]struct {
result1 error
})
}
fake.checkACLReturnsOnCall[i] = struct {
result1 error
}{result1}
}
func (fake *Support) IsJavaCC(buf []byte) (bool, error) {
var bufCopy []byte
if buf != nil {
bufCopy = make([]byte, len(buf))
copy(bufCopy, buf)
}
fake.isJavaCCMutex.Lock()
ret, specificReturn := fake.isJavaCCReturnsOnCall[len(fake.isJavaCCArgsForCall)]
fake.isJavaCCArgsForCall = append(fake.isJavaCCArgsForCall, struct {
buf []byte
}{bufCopy})
fake.recordInvocation("IsJavaCC", []interface{}{bufCopy})
fake.isJavaCCMutex.Unlock()
if fake.IsJavaCCStub != nil {
return fake.IsJavaCCStub(buf)
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.isJavaCCReturns.result1, fake.isJavaCCReturns.result2
}
func (fake *Support) IsJavaCCCallCount() int {
fake.isJavaCCMutex.RLock()
defer fake.isJavaCCMutex.RUnlock()
return len(fake.isJavaCCArgsForCall)
}
func (fake *Support) IsJavaCCArgsForCall(i int) []byte {
fake.isJavaCCMutex.RLock()
defer fake.isJavaCCMutex.RUnlock()
return fake.isJavaCCArgsForCall[i].buf
}
func (fake *Support) IsJavaCCReturns(result1 bool, result2 error) {
fake.IsJavaCCStub = nil
fake.isJavaCCReturns = struct {
result1 bool
result2 error
}{result1, result2}
}
func (fake *Support) IsJavaCCReturnsOnCall(i int, result1 bool, result2 error) {
fake.IsJavaCCStub = nil
if fake.isJavaCCReturnsOnCall == nil {
fake.isJavaCCReturnsOnCall = make(map[int]struct {
result1 bool
result2 error
})
}
fake.isJavaCCReturnsOnCall[i] = struct {
result1 bool
result2 error
}{result1, result2}
}
func (fake *Support) CheckInstantiationPolicy(name string, version string, cd ccprovider.ChaincodeDefinition) error {
fake.checkInstantiationPolicyMutex.Lock()
ret, specificReturn := fake.checkInstantiationPolicyReturnsOnCall[len(fake.checkInstantiationPolicyArgsForCall)]
fake.checkInstantiationPolicyArgsForCall = append(fake.checkInstantiationPolicyArgsForCall, struct {
name string
version string
cd ccprovider.ChaincodeDefinition
}{name, version, cd})
fake.recordInvocation("CheckInstantiationPolicy", []interface{}{name, version, cd})
fake.checkInstantiationPolicyMutex.Unlock()
if fake.CheckInstantiationPolicyStub != nil {
return fake.CheckInstantiationPolicyStub(name, version, cd)
}
if specificReturn {
return ret.result1
}
return fake.checkInstantiationPolicyReturns.result1
}
func (fake *Support) CheckInstantiationPolicyCallCount() int {
fake.checkInstantiationPolicyMutex.RLock()
defer fake.checkInstantiationPolicyMutex.RUnlock()
return len(fake.checkInstantiationPolicyArgsForCall)
}
func (fake *Support) CheckInstantiationPolicyArgsForCall(i int) (string, string, ccprovider.ChaincodeDefinition) {
fake.checkInstantiationPolicyMutex.RLock()
defer fake.checkInstantiationPolicyMutex.RUnlock()
return fake.checkInstantiationPolicyArgsForCall[i].name, fake.checkInstantiationPolicyArgsForCall[i].version, fake.checkInstantiationPolicyArgsForCall[i].cd
}
func (fake *Support) CheckInstantiationPolicyReturns(result1 error) {
fake.CheckInstantiationPolicyStub = nil
fake.checkInstantiationPolicyReturns = struct {
result1 error
}{result1}
}
func (fake *Support) CheckInstantiationPolicyReturnsOnCall(i int, result1 error) {
fake.CheckInstantiationPolicyStub = nil
if fake.checkInstantiationPolicyReturnsOnCall == nil {
fake.checkInstantiationPolicyReturnsOnCall = make(map[int]struct {
result1 error
})
}
fake.checkInstantiationPolicyReturnsOnCall[i] = struct {
result1 error
}{result1}
}
func (fake *Support) GetChaincodeDeploymentSpecFS(cds *pb.ChaincodeDeploymentSpec) (*pb.ChaincodeDeploymentSpec, error) {
fake.getChaincodeDeploymentSpecFSMutex.Lock()
ret, specificReturn := fake.getChaincodeDeploymentSpecFSReturnsOnCall[len(fake.getChaincodeDeploymentSpecFSArgsForCall)]
fake.getChaincodeDeploymentSpecFSArgsForCall = append(fake.getChaincodeDeploymentSpecFSArgsForCall, struct {
cds *pb.ChaincodeDeploymentSpec
}{cds})
fake.recordInvocation("GetChaincodeDeploymentSpecFS", []interface{}{cds})
fake.getChaincodeDeploymentSpecFSMutex.Unlock()
if fake.GetChaincodeDeploymentSpecFSStub != nil {
return fake.GetChaincodeDeploymentSpecFSStub(cds)
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.getChaincodeDeploymentSpecFSReturns.result1, fake.getChaincodeDeploymentSpecFSReturns.result2
}
func (fake *Support) GetChaincodeDeploymentSpecFSCallCount() int {
fake.getChaincodeDeploymentSpecFSMutex.RLock()
defer fake.getChaincodeDeploymentSpecFSMutex.RUnlock()
return len(fake.getChaincodeDeploymentSpecFSArgsForCall)
}
func (fake *Support) GetChaincodeDeploymentSpecFSArgsForCall(i int) *pb.ChaincodeDeploymentSpec {
fake.getChaincodeDeploymentSpecFSMutex.RLock()
defer fake.getChaincodeDeploymentSpecFSMutex.RUnlock()
return fake.getChaincodeDeploymentSpecFSArgsForCall[i].cds
}
func (fake *Support) GetChaincodeDeploymentSpecFSReturns(result1 *pb.ChaincodeDeploymentSpec, result2 error) {
fake.GetChaincodeDeploymentSpecFSStub = nil
fake.getChaincodeDeploymentSpecFSReturns = struct {
result1 *pb.ChaincodeDeploymentSpec
result2 error
}{result1, result2}
}
func (fake *Support) GetChaincodeDeploymentSpecFSReturnsOnCall(i int, result1 *pb.ChaincodeDeploymentSpec, result2 error) {
fake.GetChaincodeDeploymentSpecFSStub = nil
if fake.getChaincodeDeploymentSpecFSReturnsOnCall == nil {
fake.getChaincodeDeploymentSpecFSReturnsOnCall = make(map[int]struct {
result1 *pb.ChaincodeDeploymentSpec
result2 error
})
}
fake.getChaincodeDeploymentSpecFSReturnsOnCall[i] = struct {
result1 *pb.ChaincodeDeploymentSpec
result2 error
}{result1, result2}
}
func (fake *Support) GetApplicationConfig(cid string) (channelconfig.Application, bool) {
fake.getApplicationConfigMutex.Lock()
ret, specificReturn := fake.getApplicationConfigReturnsOnCall[len(fake.getApplicationConfigArgsForCall)]
fake.getApplicationConfigArgsForCall = append(fake.getApplicationConfigArgsForCall, struct {
cid string
}{cid})
fake.recordInvocation("GetApplicationConfig", []interface{}{cid})
fake.getApplicationConfigMutex.Unlock()
if fake.GetApplicationConfigStub != nil {
return fake.GetApplicationConfigStub(cid)
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.getApplicationConfigReturns.result1, fake.getApplicationConfigReturns.result2
}
func (fake *Support) GetApplicationConfigCallCount() int {
fake.getApplicationConfigMutex.RLock()
defer fake.getApplicationConfigMutex.RUnlock()
return len(fake.getApplicationConfigArgsForCall)
}
func (fake *Support) GetApplicationConfigArgsForCall(i int) string {
fake.getApplicationConfigMutex.RLock()
defer fake.getApplicationConfigMutex.RUnlock()
return fake.getApplicationConfigArgsForCall[i].cid
}
func (fake *Support) GetApplicationConfigReturns(result1 channelconfig.Application, result2 bool) {
fake.GetApplicationConfigStub = nil
fake.getApplicationConfigReturns = struct {
result1 channelconfig.Application
result2 bool
}{result1, result2}
}
func (fake *Support) GetApplicationConfigReturnsOnCall(i int, result1 channelconfig.Application, result2 bool) {
fake.GetApplicationConfigStub = nil
if fake.getApplicationConfigReturnsOnCall == nil {
fake.getApplicationConfigReturnsOnCall = make(map[int]struct {
result1 channelconfig.Application
result2 bool
})
}
fake.getApplicationConfigReturnsOnCall[i] = struct {
result1 channelconfig.Application
result2 bool
}{result1, result2}
}
func (fake *Support) NewQueryCreator(channel string) (endorser_test.QueryCreator, error) {
fake.newQueryCreatorMutex.Lock()
ret, specificReturn := fake.newQueryCreatorReturnsOnCall[len(fake.newQueryCreatorArgsForCall)]
fake.newQueryCreatorArgsForCall = append(fake.newQueryCreatorArgsForCall, struct {
channel string
}{channel})
fake.recordInvocation("NewQueryCreator", []interface{}{channel})
fake.newQueryCreatorMutex.Unlock()
if fake.NewQueryCreatorStub != nil {
return fake.NewQueryCreatorStub(channel)
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.newQueryCreatorReturns.result1, fake.newQueryCreatorReturns.result2
}
func (fake *Support) NewQueryCreatorCallCount() int {
fake.newQueryCreatorMutex.RLock()
defer fake.newQueryCreatorMutex.RUnlock()
return len(fake.newQueryCreatorArgsForCall)
}
func (fake *Support) NewQueryCreatorArgsForCall(i int) string {
fake.newQueryCreatorMutex.RLock()
defer fake.newQueryCreatorMutex.RUnlock()
return fake.newQueryCreatorArgsForCall[i].channel
}
func (fake *Support) NewQueryCreatorReturns(result1 endorser_test.QueryCreator, result2 error) {
fake.NewQueryCreatorStub = nil
fake.newQueryCreatorReturns = struct {
result1 endorser_test.QueryCreator
result2 error
}{result1, result2}
}
func (fake *Support) NewQueryCreatorReturnsOnCall(i int, result1 endorser_test.QueryCreator, result2 error) {
fake.NewQueryCreatorStub = nil
if fake.newQueryCreatorReturnsOnCall == nil {
fake.newQueryCreatorReturnsOnCall = make(map[int]struct {
result1 endorser_test.QueryCreator
result2 error
})
}
fake.newQueryCreatorReturnsOnCall[i] = struct {
result1 endorser_test.QueryCreator
result2 error
}{result1, result2}
}
func (fake *Support) EndorseWithPlugin(ctx endorser_test.Context) (*pb.ProposalResponse, error) {
fake.endorseWithPluginMutex.Lock()
ret, specificReturn := fake.endorseWithPluginReturnsOnCall[len(fake.endorseWithPluginArgsForCall)]
fake.endorseWithPluginArgsForCall = append(fake.endorseWithPluginArgsForCall, struct {
ctx endorser_test.Context
}{ctx})
fake.recordInvocation("EndorseWithPlugin", []interface{}{ctx})
fake.endorseWithPluginMutex.Unlock()
if fake.EndorseWithPluginStub != nil {
return fake.EndorseWithPluginStub(ctx)
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.endorseWithPluginReturns.result1, fake.endorseWithPluginReturns.result2
}
func (fake *Support) EndorseWithPluginCallCount() int {
fake.endorseWithPluginMutex.RLock()
defer fake.endorseWithPluginMutex.RUnlock()
return len(fake.endorseWithPluginArgsForCall)
}
func (fake *Support) EndorseWithPluginArgsForCall(i int) endorser_test.Context {
fake.endorseWithPluginMutex.RLock()
defer fake.endorseWithPluginMutex.RUnlock()
return fake.endorseWithPluginArgsForCall[i].ctx
}
func (fake *Support) EndorseWithPluginReturns(result1 *pb.ProposalResponse, result2 error) {
fake.EndorseWithPluginStub = nil
fake.endorseWithPluginReturns = struct {
result1 *pb.ProposalResponse
result2 error
}{result1, result2}
}
func (fake *Support) EndorseWithPluginReturnsOnCall(i int, result1 *pb.ProposalResponse, result2 error) {
fake.EndorseWithPluginStub = nil
if fake.endorseWithPluginReturnsOnCall == nil {
fake.endorseWithPluginReturnsOnCall = make(map[int]struct {
result1 *pb.ProposalResponse
result2 error
})
}
fake.endorseWithPluginReturnsOnCall[i] = struct {
result1 *pb.ProposalResponse
result2 error
}{result1, result2}
}
func (fake *Support) GetLedgerHeight(channelID string) (uint64, error) {
fake.getLedgerHeightMutex.Lock()
ret, specificReturn := fake.getLedgerHeightReturnsOnCall[len(fake.getLedgerHeightArgsForCall)]
fake.getLedgerHeightArgsForCall = append(fake.getLedgerHeightArgsForCall, struct {
channelID string
}{channelID})
fake.recordInvocation("GetLedgerHeight", []interface{}{channelID})
fake.getLedgerHeightMutex.Unlock()
if fake.GetLedgerHeightStub != nil {
return fake.GetLedgerHeightStub(channelID)
}
if specificReturn {
return ret.result1, ret.result2
}
return fake.getLedgerHeightReturns.result1, fake.getLedgerHeightReturns.result2
}
func (fake *Support) GetLedgerHeightCallCount() int {
fake.getLedgerHeightMutex.RLock()
defer fake.getLedgerHeightMutex.RUnlock()
return len(fake.getLedgerHeightArgsForCall)
}
func (fake *Support) GetLedgerHeightArgsForCall(i int) string {
fake.getLedgerHeightMutex.RLock()
defer fake.getLedgerHeightMutex.RUnlock()
return fake.getLedgerHeightArgsForCall[i].channelID
}
func (fake *Support) GetLedgerHeightReturns(result1 uint64, result2 error) {
fake.GetLedgerHeightStub = nil
fake.getLedgerHeightReturns = struct {
result1 uint64
result2 error
}{result1, result2}
}
func (fake *Support) GetLedgerHeightReturnsOnCall(i int, result1 uint64, result2 error) {
fake.GetLedgerHeightStub = nil
if fake.getLedgerHeightReturnsOnCall == nil {
fake.getLedgerHeightReturnsOnCall = make(map[int]struct {
result1 uint64
result2 error
})
}
fake.getLedgerHeightReturnsOnCall[i] = struct {
result1 uint64
result2 error
}{result1, result2}
}
func (fake *Support) Invocations() map[string][][]interface{} {
fake.invocationsMutex.RLock()
defer fake.invocationsMutex.RUnlock()
fake.signMutex.RLock()
defer fake.signMutex.RUnlock()
fake.serializeMutex.RLock()
defer fake.serializeMutex.RUnlock()
fake.isSysCCAndNotInvokableExternalMutex.RLock()
defer fake.isSysCCAndNotInvokableExternalMutex.RUnlock()
fake.getTxSimulatorMutex.RLock()
defer fake.getTxSimulatorMutex.RUnlock()
fake.getHistoryQueryExecutorMutex.RLock()
defer fake.getHistoryQueryExecutorMutex.RUnlock()
fake.getTransactionByIDMutex.RLock()
defer fake.getTransactionByIDMutex.RUnlock()
fake.isSysCCMutex.RLock()
defer fake.isSysCCMutex.RUnlock()
fake.executeMutex.RLock()
defer fake.executeMutex.RUnlock()
fake.getChaincodeDefinitionMutex.RLock()
defer fake.getChaincodeDefinitionMutex.RUnlock()
fake.checkACLMutex.RLock()
defer fake.checkACLMutex.RUnlock()
fake.isJavaCCMutex.RLock()
defer fake.isJavaCCMutex.RUnlock()
fake.checkInstantiationPolicyMutex.RLock()
defer fake.checkInstantiationPolicyMutex.RUnlock()
fake.getChaincodeDeploymentSpecFSMutex.RLock()
defer fake.getChaincodeDeploymentSpecFSMutex.RUnlock()
fake.getApplicationConfigMutex.RLock()
defer fake.getApplicationConfigMutex.RUnlock()
fake.newQueryCreatorMutex.RLock()
defer fake.newQueryCreatorMutex.RUnlock()
fake.endorseWithPluginMutex.RLock()
defer fake.endorseWithPluginMutex.RUnlock()
fake.getLedgerHeightMutex.RLock()
defer fake.getLedgerHeightMutex.RUnlock()
copiedInvocations := map[string][][]interface{}{}
for key, value := range fake.invocations {
copiedInvocations[key] = value
}
return copiedInvocations
}
func (fake *Support) recordInvocation(key string, args []interface{}) {
fake.invocationsMutex.Lock()
defer fake.invocationsMutex.Unlock()
if fake.invocations == nil {
fake.invocations = map[string][][]interface{}{}
}
if fake.invocations[key] == nil {
fake.invocations[key] = [][]interface{}{}
}
fake.invocations[key] = append(fake.invocations[key], args)
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/venjia/fabric.git
git@gitee.com:venjia/fabric.git
venjia
fabric
fabric
v1.2.0

搜索帮助