pub struct ScenarioReceipt { /* private fields */ }Expand description
A test-owned receipt recorder attached to one TestSimulator.
It accepts only bounded ASCII identifiers and finite enums so test evidence cannot accidentally include request payloads, secrets, or arbitrary errors.
Implementations§
Source§impl ScenarioReceipt
impl ScenarioReceipt
Sourcepub fn transition(
&self,
generation_id: &str,
operation_id: &str,
transition: ScenarioTransition,
) -> Result<(), FaultPointError>
pub fn transition( &self, generation_id: &str, operation_id: &str, transition: ScenarioTransition, ) -> Result<(), FaultPointError>
Records one non-terminal transition.
Sourcepub fn fault(
&self,
generation_id: &str,
operation_id: &str,
transition: ScenarioTransition,
fault: SimulatorFault,
) -> Result<(), FaultPointError>
pub fn fault( &self, generation_id: &str, operation_id: &str, transition: ScenarioTransition, fault: SimulatorFault, ) -> Result<(), FaultPointError>
Records one explicitly injected fault at the current boundary.
Sourcepub fn terminal(
&self,
generation_id: &str,
operation_id: &str,
terminal: ScenarioTerminal,
) -> Result<(), FaultPointError>
pub fn terminal( &self, generation_id: &str, operation_id: &str, terminal: ScenarioTerminal, ) -> Result<(), FaultPointError>
Records one terminal result.
Sourcepub fn events(&self) -> Vec<ScenarioReceiptEvent>
pub fn events(&self) -> Vec<ScenarioReceiptEvent>
Returns a stable snapshot in record order.
Trait Implementations§
Source§impl Clone for ScenarioReceipt
impl Clone for ScenarioReceipt
Auto Trait Implementations§
impl !RefUnwindSafe for ScenarioReceipt
impl !Send for ScenarioReceipt
impl !Sync for ScenarioReceipt
impl !UnwindSafe for ScenarioReceipt
impl Freeze for ScenarioReceipt
impl Unpin for ScenarioReceipt
impl UnsafeUnpin for ScenarioReceipt
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more