integration

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 16, 2022 License: Apache-2.0 Imports: 24 Imported by: 7

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	StartPort int
}

type Infrastructure

type Infrastructure struct {
	TestDir           string
	StartPort         int
	Ctx               *context.Context
	NWO               *nwo.NWO
	BuildServer       *common.BuildServer
	DeleteOnStop      bool
	DeleteOnStart     bool
	PlatformFactories map[string]api.PlatformFactory
	Topologies        []api.Topology
	FscPlatform       *fsc.Platform
}

func Clients

func Clients(dir string, topologies ...api.Topology) (*Infrastructure, error)

Clients instantiate a new test integration infrastructure to access view client and CLI

func Generate

func Generate(startPort int, race bool, topologies ...api.Topology) (*Infrastructure, error)

func GenerateAt

func GenerateAt(startPort int, path string, race bool, topologies ...api.Topology) (*Infrastructure, error)

func Load

func Load(startPort int, dir string, race bool, topologies ...api.Topology) (*Infrastructure, error)

func New

func New(startPort int, path string, topologies ...api.Topology) (*Infrastructure, error)

func (*Infrastructure) Admin

func (i *Infrastructure) Admin(name string) api.ViewClient

func (*Infrastructure) CLI

func (i *Infrastructure) CLI(name string) api.ViewClient

func (*Infrastructure) Client

func (i *Infrastructure) Client(name string) api.ViewClient

func (*Infrastructure) EnableRaceDetector

func (i *Infrastructure) EnableRaceDetector()

func (*Infrastructure) Generate

func (i *Infrastructure) Generate()

func (*Infrastructure) Identity

func (i *Infrastructure) Identity(name string) view.Identity

func (*Infrastructure) InitClients

func (i *Infrastructure) InitClients()

func (*Infrastructure) Load

func (i *Infrastructure) Load()

func (*Infrastructure) RegisterPlatformFactory

func (i *Infrastructure) RegisterPlatformFactory(factory api.PlatformFactory)

func (*Infrastructure) Serve

func (i *Infrastructure) Serve() error

func (*Infrastructure) Start

func (i *Infrastructure) Start()

func (*Infrastructure) StartFSCNode

func (i *Infrastructure) StartFSCNode(id string)

func (*Infrastructure) Stop

func (i *Infrastructure) Stop()

func (*Infrastructure) StopFSCNode

func (i *Infrastructure) StopFSCNode(id string)

func (*Infrastructure) ViewCmd

func (i *Infrastructure) ViewCmd(node *smartclient.Peer) commands.View

type TestPortRange

type TestPortRange int

TestPortRange represents a port range

const (
	BasePort TestPortRange = basePort + portsPerSuite*iota
	PingPongPort
	PingPong2Port
	PingPongWithAdminPort
	IOUPort
	IOUHSMPort
	IOUWithOrionBackendPort
	AssetTransferSecuredAgreementWithChaincode
	AssetTransferSecuredAgreementWithApprovers
	AssetTransferEventsAgreementWithChaincode
	TwoFabricNetworksPort
	FPCEchoPort
	TwoFabricNetworksWithWeaverRelayPort
	FabricStopRestart
	PingPongOrion
)

func (TestPortRange) StartPortForNode

func (t TestPortRange) StartPortForNode() int

StartPortForNode On linux, the default ephemeral port range is 32768-60999 and can be allocated by the system for the client side of TCP connections or when programs explicitly request one. Given linux is our default CI system, we want to try avoid ports in that range.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL