minion_engine/control_flow.rs
1use crate::steps::StepOutput;
2
3/// Control flow exceptions (like Roast's skip!/break!/fail!)
4#[derive(Debug)]
5#[allow(dead_code)]
6pub enum ControlFlow {
7 /// Skip the current step without error
8 Skip { message: String },
9
10 /// Fail the step and potentially abort
11 Fail { message: String },
12
13 /// Exit the current repeat/map loop
14 Break {
15 message: String,
16 value: Option<StepOutput>,
17 },
18
19 /// Skip to next iteration of repeat/map
20 Next { message: String },
21}