Documentation ¶
Index ¶
- Constants
- Variables
- func Check(t *testing.T, err error)
- func CompareStates(spec *common.Spec, a common.BeaconState, b common.BeaconState) (diff string, err error)
- func LoadSSZ(t *testing.T, name string, dst codec.Deserializable, readPart TestPartReader) bool
- func LoadSpecObj(t *testing.T, name string, dst common.SpecObj, readPart TestPartReader) bool
- func LoadState(t *testing.T, fork ForkName, name string, readPart TestPartReader) common.BeaconState
- func RunHandler(t *testing.T, handlerPath string, caseRunner CaseRunner, spec *common.Spec, ...)
- func RunTransitionTest(t *testing.T, forks []ForkName, runnerName string, handlerName string, ...)
- type BLSMeta
- type BaseTransitionTest
- type BlocksCountMeta
- type BlocksTestCase
- type CaseRunner
- type ForkName
- type TestPart
- type TestPartReader
- type TransitionCaseMaker
- type TransitionTest
Constants ¶
View Source
const ( BlsOptional = 0 BlsRequired = 1 BlsIgnored = 2 )
Variables ¶
View Source
var AllForks = []ForkName{"phase0", "altair", "bellatrix", "capella", "deneb"}
Functions ¶
func CompareStates ¶ added in v0.12.1
func CompareStates(spec *common.Spec, a common.BeaconState, b common.BeaconState) (diff string, err error)
func LoadSSZ ¶ added in v0.8.2
func LoadSSZ(t *testing.T, name string, dst codec.Deserializable, readPart TestPartReader) bool
func LoadSpecObj ¶ added in v0.12.2
func LoadState ¶ added in v0.12.1
func LoadState(t *testing.T, fork ForkName, name string, readPart TestPartReader) common.BeaconState
func RunHandler ¶ added in v0.8.2
func RunTransitionTest ¶ added in v0.8.2
Types ¶
type BaseTransitionTest ¶ added in v0.8.2
type BaseTransitionTest struct { Spec *common.Spec Fork ForkName Pre common.BeaconState Post common.BeaconState }
func (*BaseTransitionTest) Check ¶ added in v0.8.2
func (c *BaseTransitionTest) Check(t *testing.T)
func (*BaseTransitionTest) ExpectingFailure ¶ added in v0.8.2
func (c *BaseTransitionTest) ExpectingFailure() bool
func (*BaseTransitionTest) Load ¶ added in v0.8.2
func (c *BaseTransitionTest) Load(t *testing.T, forkName ForkName, readPart TestPartReader)
type BlocksCountMeta ¶ added in v0.20.0
type BlocksCountMeta struct {
BlocksCount uint64 `yaml:"blocks_count"`
}
type BlocksTestCase ¶ added in v0.20.0
type BlocksTestCase struct { BaseTransitionTest Blocks []*common.BeaconBlockEnvelope }
func (*BlocksTestCase) Load ¶ added in v0.20.0
func (c *BlocksTestCase) Load(t *testing.T, forkName ForkName, readPart TestPartReader)
func (*BlocksTestCase) Run ¶ added in v0.20.0
func (c *BlocksTestCase) Run() error
type CaseRunner ¶ added in v0.8.2
type CaseRunner func(t *testing.T, forkName ForkName, readPart TestPartReader)
Runs a test case
func HandleBLS ¶ added in v0.8.2
func HandleBLS(testRunner CaseRunner) CaseRunner
type ForkName ¶ added in v0.16.0
type ForkName string
Fork where the test is organized, and thus the state/block/etc. types default to.
type TestPartReader ¶ added in v0.8.2
type TransitionCaseMaker ¶ added in v0.8.2
type TransitionCaseMaker func() TransitionTest
type TransitionTest ¶ added in v0.8.2
Click to show internal directories.
Click to hide internal directories.