Scenario design
Each journey drawn as a graph, and the path every Gherkin scenario walks on it. Kept as code in designs/, beside features/.
A test design maps every state a user, an order or a file can go through, and the transitions between them, before or beside the scenarios. Each scenario is then a path on the map. Plain grey transitions are walked by at least one scenario, dashed red ones by none: the gaps to discuss with the product owner. Clicking a scenario highlights its path in blue; Run runs it on the stack through the Gherkin runner.
Shapes: blue stadium, where a journey starts; hexagon, a check; white box, a state; green, a good outcome; red, a refusal or a failure.
Bucket checks, the contract of a team bucket
The same generic checks run on every team bucket, each bucket being one row of examples (finance-exports, catalog-feeds). The design shows the path of a healthy bucket, and in red every way a bucket can break that no example proves yet: a broken file deserves a bucket of its own in the examples, so the test shows it is caught.
flowchart TD
bucket(["A team bucket one row of examples"]):::start
listed{{"Files under the prefix?"}}:::check
names{{"Names match the pattern?"}}:::check
sizes{{"No empty file?"}}:::check
format{{"Every file reads as its format?"}}:::check
fresh{{"Newest file fresh enough?"}}:::check
kept(["Contract kept"]):::outcome
manifest{{"Manifest lists exactly the files?"}}:::check
in_sync(["Manifest in sync"]):::outcome
schema{{"Columns and fields as agreed?"}}:::check
no_file(["Nothing delivered"]):::failure
bad_name(["Misnamed file"]):::failure
empty(["Empty file"]):::failure
unreadable(["Unreadable file"]):::failure
stale(["Stale delivery"]):::failure
drift(["Missing or unlisted file"]):::failure
bucket -->|"list the prefix"| listed
listed -->|"no"| no_file
listed -->|"yes"| names
names -->|"no"| bad_name
names -->|"yes"| sizes
sizes -->|"no"| empty
sizes -->|"yes"| format
format -->|"no"| unreadable
format -->|"yes"| fresh
format -->|"read the content"| schema
fresh -->|"no"| stale
fresh -->|"yes"| kept
listed -->|"read manifest.json"| manifest
manifest -->|"yes"| in_sync
manifest -->|"no"| drift
linkStyle 0 stroke:#2563eb,stroke-width:4px
linkStyle 1 stroke:#ef4444,stroke-width:1.5px,stroke-dasharray:5 4
linkStyle 2 stroke:#64748b,stroke-width:1.5px
linkStyle 3 stroke:#ef4444,stroke-width:1.5px,stroke-dasharray:5 4
linkStyle 4 stroke:#64748b,stroke-width:1.5px
linkStyle 5 stroke:#ef4444,stroke-width:1.5px,stroke-dasharray:5 4
linkStyle 6 stroke:#64748b,stroke-width:1.5px
linkStyle 7 stroke:#ef4444,stroke-width:1.5px,stroke-dasharray:5 4
linkStyle 8 stroke:#64748b,stroke-width:1.5px
linkStyle 9 stroke:#ef4444,stroke-width:1.5px,stroke-dasharray:5 4
linkStyle 10 stroke:#ef4444,stroke-width:1.5px,stroke-dasharray:5 4
linkStyle 11 stroke:#64748b,stroke-width:1.5px
linkStyle 12 stroke:#2563eb,stroke-width:4px
linkStyle 13 stroke:#2563eb,stroke-width:4px
linkStyle 14 stroke:#ef4444,stroke-width:1.5px,stroke-dasharray:5 4
classDef start fill:#dbeafe,stroke:#2563eb,color:#0f172a
classDef state fill:#ffffff,stroke:#94a3b8,color:#0f172a
classDef check fill:#fef3c7,stroke:#b45309,color:#0f172a
classDef outcome fill:#dcfce7,stroke:#15803d,color:#0f172a
classDef failure fill:#fee2e2,stroke:#b91c1c,color:#0f172aGaps: transitions no scenario walks
| From | Transition | To |
|---|---|---|
| Files under the prefix? | no | Nothing delivered |
| Names match the pattern? | no | Misnamed file |
| No empty file? | no | Empty file |
| Every file reads as its format? | no | Unreadable file |
| Every file reads as its format? | read the content | Columns and fields as agreed? |
| Newest file fresh enough? | no | Stale delivery |
| Manifest lists exactly the files? | no | Missing or unlisted file |