tests

package
v0.2507.0 Latest Latest
Warning

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

Go to latest
Published: Nov 6, 2025 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package tests is a collection of beacon implementation test cases.

Index

Constants

This section is empty.

Variables

View Source
var TestSigner = memorySigner.NewTestSigner("oasis-core epochtime mock key seed")

TestSigner is a test signer used for setting epochs in tests.

Functions

func BeaconImplementationTests

func BeaconImplementationTests(t *testing.T, consensus consensusAPI.Service)

BeaconImplementationTests exercises the basic functionality of a beacon backend.

func EpochtimeSetableImplementationTest added in v0.2100.0

func EpochtimeSetableImplementationTest(t *testing.T, consensus consensusAPI.Service)

EpochtimeSetableImplementationTest exercises the basic functionality of a setable (mock) epochtime backend.

func MustAdvanceEpoch added in v0.2100.0

func MustAdvanceEpoch(t *testing.T, consensus consensusAPI.Service) api.EpochTime

MustAdvanceEpoch advances the epoch and returns the new epoch.

func MustAdvanceEpochMulti added in v0.2103.0

func MustAdvanceEpochMulti(t *testing.T, consensus consensusAPI.Service, increment uint64) api.EpochTime

MustAdvanceEpochMulti advances the epoch by the specified increment, and returns the new epoch. Between each epoch increment the method ensures that the consensus validator is re-registered so that epochs are not advanced too fast, which could cause a consensus error due to no validators being registered for the epoch.

func SetEpoch added in v0.2503.0

func SetEpoch(ctx context.Context, epoch api.EpochTime, consensus consensusAPI.Service) error

SetEpoch sets the current epoch.

Types

This section is empty.

Jump to

Keyboard shortcuts

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