Trait ef_tests::case::Case

source ·
pub trait Case:
    Debug
    + Sync
    + Sized {
    // Required methods
    fn load(path: &Path) -> Result<Self, Error>;
    fn run(&self) -> Result<(), Error>;

    // Provided method
    fn description(&self) -> String { ... }
}
Expand description

A single test case, capable of loading a JSON description of itself and running it.

See https://ethereum-tests.readthedocs.io/ for test specs.

Required Methods§

source

fn load(path: &Path) -> Result<Self, Error>

Load the test from the given file path.

The file can be assumed to be a valid EF test case as described on https://ethereum-tests.readthedocs.io/.

source

fn run(&self) -> Result<(), Error>

Run the test.

Provided Methods§

source

fn description(&self) -> String

A description of the test.

Object Safety§

This trait is not object safe.

Implementors§