github.com/lzy4123/fabric@v2.1.1+incompatible/core/chaincode/persistence/persistence_suite_test.go (about)

     1  /*
     2  Copyright IBM Corp. All Rights Reserved.
     3  
     4  SPDX-License-Identifier: Apache-2.0
     5  */
     6  
     7  package persistence_test
     8  
     9  import (
    10  	"os"
    11  	"testing"
    12  
    13  	"github.com/hyperledger/fabric/core/chaincode/persistence"
    14  	. "github.com/onsi/ginkgo"
    15  	. "github.com/onsi/gomega"
    16  )
    17  
    18  //go:generate counterfeiter -o mock/ioreadwriter.go -fake-name IOReadWriter . ioReadWriter
    19  type ioReadWriter interface {
    20  	persistence.IOReadWriter
    21  }
    22  
    23  //go:generate counterfeiter -o mock/osfileinfo.go -fake-name OSFileInfo . osFileInfo
    24  type osFileInfo interface {
    25  	os.FileInfo
    26  }
    27  
    28  //go:generate mockery -dir . -name MetadataProvider -case underscore -output mock/ -outpkg mock
    29  
    30  func TestPersistence(t *testing.T) {
    31  	RegisterFailHandler(Fail)
    32  	RunSpecs(t, "Persistence Suite")
    33  }