pub trait Scenario: Any {
// Required method
fn run(
&self,
env: &HostEnv,
container: &DeployedContractsContainer,
args: ScenarioArgs<'_>,
) -> Result<(), ScenarioError>;
// Provided method
fn args(&self) -> Vec<CommandArg> { ... }
}Expand description
Scenario is a trait that represents a custom scenario.
A scenario is a user-defined set of actions that can be run in the Odra CLI. If you want to run a custom scenario that calls multiple entry points, you need to implement this trait.
Required Methods§
fn run( &self, env: &HostEnv, container: &DeployedContractsContainer, args: ScenarioArgs<'_>, ) -> Result<(), ScenarioError>
Provided Methods§
fn args(&self) -> Vec<CommandArg>
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".