share

package
v0.3.6 Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2024 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EncodingTest added in v0.3.0

type EncodingTest struct {
	Name         string
	Data         []byte
	ExpectedRoot [32]byte
}

func Encoding

func Encoding() *EncodingTest

Encoding tests encoding of a ssv message

func (*EncodingTest) Run added in v0.3.0

func (test *EncodingTest) Run(t *testing.T)

func (*EncodingTest) TestName added in v0.3.0

func (test *EncodingTest) TestName() string

type ShareTest added in v0.3.5

type ShareTest struct {
	Name                     string
	Share                    types.Share
	Message                  qbft.SignedMessage
	ExpectedHasPartialQuorum bool
	ExpectedHasQuorum        bool
	ExpectedFullCommittee    bool
	ExpectedError            string
}

func HasPartialQuorumButNoQuorum added in v0.3.5

func HasPartialQuorumButNoQuorum() *ShareTest

HasPartialQuorumButNoQuorum tests msg with unique f+1 signers

func HasQuorum added in v0.2.7

func HasQuorum() *ShareTest

HasQuorum tests msg with unique 2f+1 signers

func HasQuorum3f1 added in v0.2.7

func HasQuorum3f1() *ShareTest

HasQuorum3f1 tests msg with unique 3f+1 signers

func NoPartialQuorum added in v0.2.7

func NoPartialQuorum() *ShareTest

NoPartialQuorum tests msg with < unique f+1 signers

func NoPartialQuorumDuplicate added in v0.2.7

func NoPartialQuorumDuplicate() *ShareTest

NoPartialQuorumDuplicate tests msg with < unique f+1 signers (but f+1 signers including duplicates)

func NoQuorumDuplicate added in v0.2.7

func NoQuorumDuplicate() *ShareTest

NoQuorumDuplicate tests msg with < unique 2f+1 signers (but 2f+1 signers including duplicates)

func PartialQuorumWithDuplicate added in v0.2.7

func PartialQuorumWithDuplicate() *ShareTest

PartialQuorumWithDuplicate tests msg with unique f+1 signers (but also including duplicates)

func QuorumWithDuplicate added in v0.2.7

func QuorumWithDuplicate() *ShareTest

QuorumWithDuplicate tests msg with unique 2f+1 signers (but also including duplicates)

func (*ShareTest) GetUniqueMessageSignersCount added in v0.3.5

func (test *ShareTest) GetUniqueMessageSignersCount() int

Returns the number of unique signers in the message signers list

func (*ShareTest) Run added in v0.3.5

func (test *ShareTest) Run(t *testing.T)

func (*ShareTest) TestName added in v0.3.5

func (test *ShareTest) TestName() string

Jump to

Keyboard shortcuts

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