labs/flow
| Step | Summary |
|---|---|
labs/flow/for_each |
Run a nested list of steps once for every item of a list. |
labs/flow/for_each
Run a nested list of steps once for every item of a list.
The nested steps resolve their with: when they run, not when the loop starts, which is what lets them read ${{ each.item }}. The loop stops at the first nested failure and fails with it; a step that reports an outcome instead of failing — a delete answering 404 — keeps it going.
Inputs
| Parameter | Type | Required | Default | Also accepts | Description |
|---|---|---|---|---|---|
items |
list of any | yes | — | — | The values to loop over, usually a list a previous step returned. An empty list runs nothing and passes. |
steps |
list of StepDefinition | yes | — | — | Nested step definitions run once per item, in order — the same shape used at the top level of a test. They read the current item as '${{ each.item }}' and its position, from 0, as '${{ each.index }}'. |
Output — the value assertions and returns: read
How many items the loop ran for, and what each run produced.
| Field | Type | Description |
|---|---|---|
iterations |
integer | Number of items the nested steps ran for. |
outputs |
list of list of any | Per item, in order, the outputs of the nested steps. |
Nested objects
Assertion
Assertion using uses / with verb-form keys.
| Field | Type | Required | Default | Also accepts | Description |
|---|---|---|---|---|---|
cac |
list of string | no | None |
— | |
uses |
string | yes | — | — | |
name |
string | no | None |
— | |
with |
object | no | None |
— |
CheckpointMark
What a test says about a step it marks a checkpoint.
| Field | Type | Required | Default | Also accepts | Description |
|---|---|---|---|---|---|
label |
string | no | None |
— | What the run calls the checkpoint. |
description |
string | no | None |
— | What whoever acts has to do, in a sentence or two. |
direction |
Direction | no | None |
— | 'inbound', 'outbound' or 'internal' — for a step type that declares no checkpoint of its own; 'outbound' when left out. |
via |
Via | no | None |
— | 'direct' or 'dataplane': how the call travels, when it does. |
ReturnFieldDefinition
Single output field declared in a step returns block.
| Field | Type | Required | Default | Also accepts | Description |
|---|---|---|---|---|---|
type |
string | yes | — | — | |
class |
string | no | None |
— | |
hidden |
boolean | no | None |
— | Mask the value in every record of the run (trace, UI, logs). |
StepDefinition
Step definition using uses and with verb-form keys.
| Field | Type | Required | Default | Also accepts | Description |
|---|---|---|---|---|---|
cac |
list of string | no | None |
— | |
id |
string | no | None |
— | |
uses |
string | yes | — | — | |
name |
string | no | None |
— | |
with |
object | no | None |
— | |
returns |
object | no | None |
— | |
validate |
list of Assertion | no | None |
— | |
expects |
fail |
no | None |
— | |
timeout_s |
number | no | None |
— | |
if |
string | no | None |
— | |
checkpoint |
boolean | CheckpointMark | no | None |
— |