util

package
v0.33.36-pebble-util Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2024 License: AGPL-3.0 Imports: 20 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MockBlockTimer added in v0.20.0

func MockBlockTimer() protocol.BlockTimer

MockBlockTimer returns BlockTimer that accepts all timestamps without performing any checks.

func MockReceiptValidator added in v0.14.0

func MockReceiptValidator() module.ReceiptValidator

MockReceiptValidator returns a ReceiptValidator that accepts all receipts without performing any integrity checks.

func MockSealValidator added in v0.14.0

func MockSealValidator(sealsDB storage.Seals) module.SealValidator

MockSealValidator returns a SealValidator that accepts all seals without performing any integrity checks, returns first seal in block as valid one

func RunWithBootstrapState added in v0.14.0

func RunWithBootstrapState(t testing.TB, rootSnapshot protocol.Snapshot, f func(*badger.DB, *pbadger.State))

func RunWithFollowerProtocolState added in v0.14.0

func RunWithFollowerProtocolState(t testing.TB, rootSnapshot protocol.Snapshot, f func(*badger.DB, *pbadger.FollowerState))

func RunWithFollowerProtocolStateAndHeaders added in v0.17.0

func RunWithFollowerProtocolStateAndHeaders(t testing.TB, rootSnapshot protocol.Snapshot, f func(*badger.DB, *pbadger.FollowerState, storage.Headers, storage.Index))

func RunWithFullProtocolState added in v0.14.0

func RunWithFullProtocolState(t testing.TB, rootSnapshot protocol.Snapshot, f func(*badger.DB, *pbadger.ParticipantState))

func RunWithFullProtocolStateAndConsumer added in v0.14.0

func RunWithFullProtocolStateAndConsumer(t testing.TB, rootSnapshot protocol.Snapshot, consumer protocol.Consumer, f func(*badger.DB, *pbadger.ParticipantState))

func RunWithFullProtocolStateAndMetrics added in v0.23.2

func RunWithFullProtocolStateAndMetrics(t testing.TB, rootSnapshot protocol.Snapshot, metrics module.ComplianceMetrics, f func(*badger.DB, *pbadger.ParticipantState))

func RunWithFullProtocolStateAndMetricsAndConsumer added in v0.29.0

func RunWithFullProtocolStateAndMetricsAndConsumer(t testing.TB, rootSnapshot protocol.Snapshot, metrics module.ComplianceMetrics, consumer protocol.Consumer, f func(*badger.DB, *pbadger.ParticipantState))

func RunWithFullProtocolStateAndValidator added in v0.14.0

func RunWithFullProtocolStateAndValidator(t testing.TB, rootSnapshot protocol.Snapshot, validator module.ReceiptValidator, f func(*badger.DB, *pbadger.ParticipantState))

func RunWithPebbleBootstrapState

func RunWithPebbleBootstrapState(t testing.TB, rootSnapshot protocol.Snapshot, f func(*pebble.DB, *pbadger.State))

func RunWithPebbleFollowerProtocolState

func RunWithPebbleFollowerProtocolState(t testing.TB, rootSnapshot protocol.Snapshot, f func(*pebble.DB, *pbadger.FollowerState))

func RunWithPebbleFollowerProtocolStateAndHeaders

func RunWithPebbleFollowerProtocolStateAndHeaders(t testing.TB, rootSnapshot protocol.Snapshot, f func(*pebble.DB, *pbadger.FollowerState, storage.Headers, storage.Index))

func RunWithPebbleFullProtocolState

func RunWithPebbleFullProtocolState(t testing.TB, rootSnapshot protocol.Snapshot, f func(*pebble.DB, *pbadger.ParticipantState))

func RunWithPebbleFullProtocolStateAndConsumer

func RunWithPebbleFullProtocolStateAndConsumer(t testing.TB, rootSnapshot protocol.Snapshot, consumer protocol.Consumer, f func(*pebble.DB, *pbadger.ParticipantState))

func RunWithPebbleFullProtocolStateAndMetrics

func RunWithPebbleFullProtocolStateAndMetrics(t testing.TB, rootSnapshot protocol.Snapshot, metrics module.ComplianceMetrics, f func(*pebble.DB, *pbadger.ParticipantState))

func RunWithPebbleFullProtocolStateAndMetricsAndConsumer

func RunWithPebbleFullProtocolStateAndMetricsAndConsumer(t testing.TB, rootSnapshot protocol.Snapshot, metrics module.ComplianceMetrics, consumer protocol.Consumer, f func(*pebble.DB, *pbadger.ParticipantState))

func RunWithPebbleFullProtocolStateAndValidator

func RunWithPebbleFullProtocolStateAndValidator(t testing.TB, rootSnapshot protocol.Snapshot, validator module.ReceiptValidator, f func(*pebble.DB, *pbadger.ParticipantState))

Types

This section is empty.

Jump to

Keyboard shortcuts

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