scenario

package
v0.2401.0 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2024 License: Apache-2.0 Imports: 3 Imported by: 2

Documentation

Overview

Package scenario implements the test scenario abstract interface.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Scenario

type Scenario interface {
	// Clone returns a copy of this scenario instance to be run in parallel.
	Clone() Scenario

	// Name returns the name of the scenario.
	//
	// Note: The name is used when selecting which tests to run, and should
	// be something suitable for use as a command line argument.
	Name() string

	// Parameters returns the settable test parameters.
	Parameters() *env.ParameterFlagSet

	// PreInit performs initial scenario initialization. It is guaranteed to be called before
	// a new fixture is initialized in Fixture.
	PreInit() error

	// Fixture returns a network fixture to use for this scenario.
	//
	// It may return nil in case the scenario doesn't use a fixture and
	// performs all setup in Init.
	Fixture() (*oasis.NetworkFixture, error)

	// Init initializes the scenario.
	//
	// Network will be provided in case Fixture returned a non-nil value,
	// otherwise it will be nil.
	Init(childEnv *env.Env, net *oasis.Network) error

	// Network returns the network used by this scenario.
	Network() *oasis.Network

	// Run runs the scenario.
	Run(ctx context.Context, childEnv *env.Env) error
}

Scenario is a test scenario identified by name.

Directories

Path Synopsis
e2e
Package e2e implements the Oasis e2e test scenarios.
Package e2e implements the Oasis e2e test scenarios.
Package pluginsigner implements the Oasis plugin-signer test scenario.
Package pluginsigner implements the Oasis plugin-signer test scenario.
example_signer_plugin
Package main implements an example oasis-node signer plugin.
Package main implements an example oasis-node signer plugin.
Package remotesigner implements the Oasis remote-signer test scenarios.
Package remotesigner implements the Oasis remote-signer test scenarios.
Package signer implements the common signer test cases.
Package signer implements the common signer test cases.

Jump to

Keyboard shortcuts

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