fabric-sdk-go: github.com/hyperledger/fabric-sdk-go/pkg/core/mocks Index | Files

package mocks

import "github.com/hyperledger/fabric-sdk-go/pkg/core/mocks"

Index

Package Files

mockconfigbackend.go mockcorecontext.go mocksigningmgr.go

func NewMockSigningManager Uses

func NewMockSigningManager() core.SigningManager

NewMockSigningManager Constructor for a mock signing manager.

type MockConfigBackend Uses

type MockConfigBackend struct {
    //KeyValueMap map to override CustomBackend key-values.
    KeyValueMap map[string]interface{}
}

MockConfigBackend mocks config backend for unit tests

func (*MockConfigBackend) Lookup Uses

func (b *MockConfigBackend) Lookup(key string) (interface{}, bool)

Lookup returns or unmarshals value for given key

type MockCoreContext Uses

type MockCoreContext struct {
    MockConfig            core.CryptoSuiteConfig
    MockCryptoSuite       core.CryptoSuite
    MockUserStore         msp.UserStore
    MockSigningManager    core.SigningManager
    MockCryptoSuiteConfig core.CryptoSuiteConfig
}

MockCoreContext is a mock core context

func (*MockCoreContext) CryptoSuite Uses

func (m *MockCoreContext) CryptoSuite() core.CryptoSuite

CryptoSuite ...

func (*MockCoreContext) CryptoSuiteConfig Uses

func (m *MockCoreContext) CryptoSuiteConfig() core.CryptoSuiteConfig

CryptoSuiteConfig ...

func (*MockCoreContext) SigningManager Uses

func (m *MockCoreContext) SigningManager() core.SigningManager

SigningManager ...

type MockSigningManager Uses

type MockSigningManager struct {
}

MockSigningManager is mock signing manager

func (*MockSigningManager) Sign Uses

func (mgr *MockSigningManager) Sign(object []byte, key core.Key) ([]byte, error)

Sign will sign the given object using provided key

Package mocks imports 2 packages (graph) and is imported by 1 packages. Updated 2018-05-11. Refresh now. Tools for package owners.