Documentation
¶
Index ¶
- func BlockchainContains(network *AlphabillPartition, criteria func(tx *txsystem.Transaction) bool) func() bool
- func BlockchainContainsTx(tx *txsystem.Transaction, network *AlphabillPartition) func() bool
- type AlphabillPartition
- func (a *AlphabillPartition) BroadcastTx(tx *txsystem.Transaction) error
- func (a *AlphabillPartition) Close() error
- func (a *AlphabillPartition) GetBlockProof(tx *txsystem.Transaction, txConverter TxConverter) (*block.GenericBlock, *block.BlockProof, error)
- func (a *AlphabillPartition) SubmitTx(tx *txsystem.Transaction) error
- type TxConverter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BlockchainContains ¶ added in v0.1.1
func BlockchainContains(network *AlphabillPartition, criteria func(tx *txsystem.Transaction) bool) func() bool
func BlockchainContainsTx ¶
func BlockchainContainsTx(tx *txsystem.Transaction, network *AlphabillPartition) func() bool
BlockchainContainsTx checks if at least one partition node block contains the given transaction.
Types ¶
type AlphabillPartition ¶
type AlphabillPartition struct {
RootChain *rootchain.RootChain
Nodes []*partition.Node
TrustBase map[string]crypto.Verifier
EventHandler *testevent.TestEventHandler
// contains filtered or unexported fields
}
AlphabillPartition for integration tests
func NewNetwork ¶
func NewNetwork(partitionNodes int, txSystemProvider func(trustBase map[string]crypto.Verifier) txsystem.TransactionSystem, systemIdentifier []byte) (*AlphabillPartition, error)
NewNetwork creates the AlphabillPartition for integration tests. It starts partition nodes with given transaction system and a root chain.
func (*AlphabillPartition) BroadcastTx ¶
func (a *AlphabillPartition) BroadcastTx(tx *txsystem.Transaction) error
BroadcastTx sends transactions to all nodes.
func (*AlphabillPartition) Close ¶
func (a *AlphabillPartition) Close() error
func (*AlphabillPartition) GetBlockProof ¶ added in v0.1.1
func (a *AlphabillPartition) GetBlockProof(tx *txsystem.Transaction, txConverter TxConverter) (*block.GenericBlock, *block.BlockProof, error)
func (*AlphabillPartition) SubmitTx ¶
func (a *AlphabillPartition) SubmitTx(tx *txsystem.Transaction) error
SubmitTx sends transactions to the first node.
type TxConverter ¶ added in v0.1.1
type TxConverter func(tx *txsystem.Transaction) (txsystem.GenericTransaction, error)
func (TxConverter) ConvertTx ¶ added in v0.1.1
func (c TxConverter) ConvertTx(tx *txsystem.Transaction) (txsystem.GenericTransaction, error)
Click to show internal directories.
Click to hide internal directories.