Skip to content

Commit 2b9a816

Browse files
sykesmale-linux
authored andcommitted
[FAB-12900] remove fake generation to foreign dir
Change-Id: I12e8b60c0b21ce7f7a7d33e899729229a6cd9c37 Signed-off-by: Matthew Sykes <sykesmat@us.ibm.com>
1 parent 81f2f0a commit 2b9a816

File tree

9 files changed

+3638
-2748
lines changed

9 files changed

+3638
-2748
lines changed

core/chaincode/shim/interfaces.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,6 @@ type Chaincode interface {
2626
Invoke(stub ChaincodeStubInterface) pb.Response
2727
}
2828

29-
//go:generate counterfeiter -o ../../scc/lscc/mock/chaincode_stub.go --fake-name ChaincodeStub . ChaincodeStubInterface
30-
//go:generate counterfeiter -o ../../chaincode/lifecycle/mock/chaincode_stub.go --fake-name ChaincodeStub . ChaincodeStubInterface
31-
3229
// ChaincodeStubInterface is used by deployable chaincode apps to access and
3330
// modify their ledgers
3431
type ChaincodeStubInterface interface {

core/scc/lscc/lscc_suite_test.go

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ package lscc_test
99
import (
1010
"testing"
1111

12+
"github.com/hyperledger/fabric/core/chaincode/shim"
1213
"github.com/hyperledger/fabric/core/common/ccprovider"
1314
"github.com/hyperledger/fabric/core/common/sysccprovider"
1415
"github.com/hyperledger/fabric/core/ledger"
@@ -37,6 +38,16 @@ type ccPackage interface {
3738
ccprovider.CCPackage
3839
}
3940

41+
//go:generate counterfeiter -o mock/chaincode_stub.go --fake-name ChaincodeStub . chaincodeStub
42+
type chaincodeStub interface {
43+
shim.ChaincodeStubInterface
44+
}
45+
46+
//go:generate counterfeiter -o mock/state_query_iterator.go --fake-name StateQueryIterator . stateQueryIterator
47+
type stateQueryIterator interface {
48+
shim.StateQueryIteratorInterface
49+
}
50+
4051
func TestLscc(t *testing.T) {
4152
RegisterFailHandler(Fail)
4253
RunSpecs(t, "Lscc Suite")

core/scc/lscc/lscc_test.go

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -47,16 +47,6 @@ import (
4747
"github.com/stretchr/testify/assert"
4848
)
4949

50-
//go:generate counterfeiter -o mock/chaincode_stub.go --fake-name ChaincodeStub . chaincodeStub
51-
type chaincodeStub interface {
52-
shim.ChaincodeStubInterface
53-
}
54-
55-
//go:generate counterfeiter -o mock/state_query_iterator.go --fake-name StateQueryIterator . stateQueryIterator
56-
type stateQueryIterator interface {
57-
shim.StateQueryIteratorInterface
58-
}
59-
6050
func constructDeploymentSpec(name string, path string, version string, initArgs [][]byte, createInvalidIndex bool, createFS bool, scc *LifeCycleSysCC) (*pb.ChaincodeDeploymentSpec, error) {
6151
spec := &pb.ChaincodeSpec{Type: pb.ChaincodeSpec_GOLANG, ChaincodeId: &pb.ChaincodeID{Name: name, Path: path, Version: version}, Input: &pb.ChaincodeInput{Args: initArgs}}
6252

0 commit comments

Comments
 (0)