fabric-sdk-go: github.com/hyperledger/fabric-sdk-go/pkg/common/providers/test/mockfab Index | Files

package mockfab

import "github.com/hyperledger/fabric-sdk-go/pkg/common/providers/test/mockfab"

Package mockfab is a generated GoMock package.

Index

Package Files

mockconfig.go mockfab.gen.go

Constants

const ErrorMessage = "default error message"

ErrorMessage is a mock error message

Variables

var BadCert = &x509.Certificate{Raw: []byte{1, 2}}

BadCert is a mock of a bad certificate

var CertPool = x509.NewCertPool()

CertPool is a mock of a *x509.CertPool

var GoodCert = &x509.Certificate{Raw: []byte{0, 1, 2}}

GoodCert is a mock of a good certificate

var TLSCert = tls.Certificate{Certificate: [][]byte{{3}, {4}}}

TLSCert is a mock of a tls.Certificate{}

type MockCertPool Uses

type MockCertPool struct {
    CertPool *x509.CertPool
    Err      error
}

MockCertPool for unit tests to mock CertPool

func (*MockCertPool) Add Uses

func (c *MockCertPool) Add(certs ...*x509.Certificate)

Add mock impl of adding certs to cert pool queue

func (*MockCertPool) Get Uses

func (c *MockCertPool) Get() (*x509.CertPool, error)

Get mock implementation of fab CertPool.Get()

type MockEndpointConfig Uses

type MockEndpointConfig struct {
    // contains filtered or unexported fields
}

MockEndpointConfig is a mock of EndpointConfig interface

func BadTLSClientMockConfig Uses

func BadTLSClientMockConfig(mockCtrl *gomock.Controller) *MockEndpointConfig

BadTLSClientMockConfig returns a mock config for testing with TLSClientCerts() that always returns an error

func CustomMockConfig Uses

func CustomMockConfig(mockCtrl *gomock.Controller, certPool *x509.CertPool) *MockEndpointConfig

CustomMockConfig returns a custom mock config with custom certpool for testing

func DefaultMockConfig Uses

func DefaultMockConfig(mockCtrl *gomock.Controller) *MockEndpointConfig

DefaultMockConfig returns a default mock config for testing

func NewMockEndpointConfig Uses

func NewMockEndpointConfig(ctrl *gomock.Controller) *MockEndpointConfig

NewMockEndpointConfig creates a new mock instance

func (*MockEndpointConfig) ChannelConfig Uses

func (m *MockEndpointConfig) ChannelConfig(arg0 string) *fab.ChannelEndpointConfig

ChannelConfig mocks base method

func (*MockEndpointConfig) ChannelOrderers Uses

func (m *MockEndpointConfig) ChannelOrderers(arg0 string) []fab.OrdererConfig

ChannelOrderers mocks base method

func (*MockEndpointConfig) ChannelPeers Uses

func (m *MockEndpointConfig) ChannelPeers(arg0 string) []fab.ChannelPeer

ChannelPeers mocks base method

func (*MockEndpointConfig) CryptoConfigPath Uses

func (m *MockEndpointConfig) CryptoConfigPath() string

CryptoConfigPath mocks base method

func (*MockEndpointConfig) EXPECT Uses

func (m *MockEndpointConfig) EXPECT() *MockEndpointConfigMockRecorder

EXPECT returns an object that allows the caller to indicate expected use

func (*MockEndpointConfig) NetworkConfig Uses

func (m *MockEndpointConfig) NetworkConfig() *fab.NetworkConfig

NetworkConfig mocks base method

func (*MockEndpointConfig) NetworkPeers Uses

func (m *MockEndpointConfig) NetworkPeers() []fab.NetworkPeer

NetworkPeers mocks base method

func (*MockEndpointConfig) OrdererConfig Uses

func (m *MockEndpointConfig) OrdererConfig(arg0 string) (*fab.OrdererConfig, bool)

OrdererConfig mocks base method

func (*MockEndpointConfig) OrderersConfig Uses

func (m *MockEndpointConfig) OrderersConfig() []fab.OrdererConfig

OrderersConfig mocks base method

func (*MockEndpointConfig) PeerConfig Uses

func (m *MockEndpointConfig) PeerConfig(arg0 string) (*fab.PeerConfig, bool)

PeerConfig mocks base method

func (*MockEndpointConfig) PeersConfig Uses

func (m *MockEndpointConfig) PeersConfig(arg0 string) ([]fab.PeerConfig, bool)

PeersConfig mocks base method

func (*MockEndpointConfig) TLSCACertPool Uses

func (m *MockEndpointConfig) TLSCACertPool() fab.CertPool

TLSCACertPool mocks base method

func (*MockEndpointConfig) TLSClientCerts Uses

func (m *MockEndpointConfig) TLSClientCerts() []tls.Certificate

TLSClientCerts mocks base method

func (*MockEndpointConfig) Timeout Uses

func (m *MockEndpointConfig) Timeout(arg0 fab.TimeoutType) time.Duration

Timeout mocks base method

type MockEndpointConfigMockRecorder Uses

type MockEndpointConfigMockRecorder struct {
    // contains filtered or unexported fields
}

MockEndpointConfigMockRecorder is the mock recorder for MockEndpointConfig

func (*MockEndpointConfigMockRecorder) ChannelConfig Uses

func (mr *MockEndpointConfigMockRecorder) ChannelConfig(arg0 interface{}) *gomock.Call

ChannelConfig indicates an expected call of ChannelConfig

func (*MockEndpointConfigMockRecorder) ChannelOrderers Uses

func (mr *MockEndpointConfigMockRecorder) ChannelOrderers(arg0 interface{}) *gomock.Call

ChannelOrderers indicates an expected call of ChannelOrderers

func (*MockEndpointConfigMockRecorder) ChannelPeers Uses

func (mr *MockEndpointConfigMockRecorder) ChannelPeers(arg0 interface{}) *gomock.Call

ChannelPeers indicates an expected call of ChannelPeers

func (*MockEndpointConfigMockRecorder) CryptoConfigPath Uses

func (mr *MockEndpointConfigMockRecorder) CryptoConfigPath() *gomock.Call

CryptoConfigPath indicates an expected call of CryptoConfigPath

func (*MockEndpointConfigMockRecorder) NetworkConfig Uses

func (mr *MockEndpointConfigMockRecorder) NetworkConfig() *gomock.Call

NetworkConfig indicates an expected call of NetworkConfig

func (*MockEndpointConfigMockRecorder) NetworkPeers Uses

func (mr *MockEndpointConfigMockRecorder) NetworkPeers() *gomock.Call

NetworkPeers indicates an expected call of NetworkPeers

func (*MockEndpointConfigMockRecorder) OrdererConfig Uses

func (mr *MockEndpointConfigMockRecorder) OrdererConfig(arg0 interface{}) *gomock.Call

OrdererConfig indicates an expected call of OrdererConfig

func (*MockEndpointConfigMockRecorder) OrderersConfig Uses

func (mr *MockEndpointConfigMockRecorder) OrderersConfig() *gomock.Call

OrderersConfig indicates an expected call of OrderersConfig

func (*MockEndpointConfigMockRecorder) PeerConfig Uses

func (mr *MockEndpointConfigMockRecorder) PeerConfig(arg0 interface{}) *gomock.Call

PeerConfig indicates an expected call of PeerConfig

func (*MockEndpointConfigMockRecorder) PeersConfig Uses

func (mr *MockEndpointConfigMockRecorder) PeersConfig(arg0 interface{}) *gomock.Call

PeersConfig indicates an expected call of PeersConfig

func (*MockEndpointConfigMockRecorder) TLSCACertPool Uses

func (mr *MockEndpointConfigMockRecorder) TLSCACertPool() *gomock.Call

TLSCACertPool indicates an expected call of TLSCACertPool

func (*MockEndpointConfigMockRecorder) TLSClientCerts Uses

func (mr *MockEndpointConfigMockRecorder) TLSClientCerts() *gomock.Call

TLSClientCerts indicates an expected call of TLSClientCerts

func (*MockEndpointConfigMockRecorder) Timeout Uses

func (mr *MockEndpointConfigMockRecorder) Timeout(arg0 interface{}) *gomock.Call

Timeout indicates an expected call of Timeout

type MockProposalProcessor Uses

type MockProposalProcessor struct {
    // contains filtered or unexported fields
}

MockProposalProcessor is a mock of ProposalProcessor interface

func NewMockProposalProcessor Uses

func NewMockProposalProcessor(ctrl *gomock.Controller) *MockProposalProcessor

NewMockProposalProcessor creates a new mock instance

func (*MockProposalProcessor) EXPECT Uses

func (m *MockProposalProcessor) EXPECT() *MockProposalProcessorMockRecorder

EXPECT returns an object that allows the caller to indicate expected use

func (*MockProposalProcessor) ProcessTransactionProposal Uses

func (m *MockProposalProcessor) ProcessTransactionProposal(arg0 context.Context, arg1 fab.ProcessProposalRequest) (*fab.TransactionProposalResponse, error)

ProcessTransactionProposal mocks base method

type MockProposalProcessorMockRecorder Uses

type MockProposalProcessorMockRecorder struct {
    // contains filtered or unexported fields
}

MockProposalProcessorMockRecorder is the mock recorder for MockProposalProcessor

func (*MockProposalProcessorMockRecorder) ProcessTransactionProposal Uses

func (mr *MockProposalProcessorMockRecorder) ProcessTransactionProposal(arg0, arg1 interface{}) *gomock.Call

ProcessTransactionProposal indicates an expected call of ProcessTransactionProposal

type MockProviders Uses

type MockProviders struct {
    // contains filtered or unexported fields
}

MockProviders is a mock of Providers interface

func NewMockProviders Uses

func NewMockProviders(ctrl *gomock.Controller) *MockProviders

NewMockProviders creates a new mock instance

func (*MockProviders) ChannelProvider Uses

func (m *MockProviders) ChannelProvider() fab.ChannelProvider

ChannelProvider mocks base method

func (*MockProviders) EXPECT Uses

func (m *MockProviders) EXPECT() *MockProvidersMockRecorder

EXPECT returns an object that allows the caller to indicate expected use

func (*MockProviders) EndpointConfig Uses

func (m *MockProviders) EndpointConfig() fab.EndpointConfig

EndpointConfig mocks base method

func (*MockProviders) GetMetrics Uses

func (m *MockProviders) GetMetrics() *metrics.ClientMetrics

GetMetrics mocks base method

func (*MockProviders) InfraProvider Uses

func (m *MockProviders) InfraProvider() fab.InfraProvider

InfraProvider mocks base method

func (*MockProviders) LocalDiscoveryProvider Uses

func (m *MockProviders) LocalDiscoveryProvider() fab.LocalDiscoveryProvider

LocalDiscoveryProvider mocks base method

type MockProvidersMockRecorder Uses

type MockProvidersMockRecorder struct {
    // contains filtered or unexported fields
}

MockProvidersMockRecorder is the mock recorder for MockProviders

func (*MockProvidersMockRecorder) ChannelProvider Uses

func (mr *MockProvidersMockRecorder) ChannelProvider() *gomock.Call

ChannelProvider indicates an expected call of ChannelProvider

func (*MockProvidersMockRecorder) EndpointConfig Uses

func (mr *MockProvidersMockRecorder) EndpointConfig() *gomock.Call

EndpointConfig indicates an expected call of EndpointConfig

func (*MockProvidersMockRecorder) GetMetrics Uses

func (mr *MockProvidersMockRecorder) GetMetrics() *gomock.Call

GetMetrics indicates an expected call of GetMetrics

func (*MockProvidersMockRecorder) InfraProvider Uses

func (mr *MockProvidersMockRecorder) InfraProvider() *gomock.Call

InfraProvider indicates an expected call of InfraProvider

func (*MockProvidersMockRecorder) LocalDiscoveryProvider Uses

func (mr *MockProvidersMockRecorder) LocalDiscoveryProvider() *gomock.Call

LocalDiscoveryProvider indicates an expected call of LocalDiscoveryProvider

Package mockfab imports 9 packages (graph) and is imported by 1 packages. Updated 2019-02-21. Refresh now. Tools for package owners.