Skip to main content

Target

Trait Target 

Source
pub trait Target: Send + Sync {
    // Required method
    fn run<'a>(
        &'a self,
        case: &'a TestCase,
    ) -> BoxFuture<'a, Result<RunCapture, EvalError>>;

    // Provided methods
    fn workflow(&self) -> WorkflowInfo { ... }
    fn start_variables(&self) -> Vec<(String, String)> { ... }
}
Expand description

The system under test: runs one test case and reports what happened.

EngineTarget runs a compiled graphrt workflow in-process; other implementations can call a server or a fake.

Required Methods§

Source

fn run<'a>( &'a self, case: &'a TestCase, ) -> BoxFuture<'a, Result<RunCapture, EvalError>>

Run case once. Return Err only when the run could not be attempted; a failed run is a capture with RunStatus::Failed.

Provided Methods§

Source

fn workflow(&self) -> WorkflowInfo

Describes the workflow for the report.

Source

fn start_variables(&self) -> Vec<(String, String)>

The start variables and their input types (paragraph, json…), used to shape judge inputs. Empty when unknown.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§