Skip to content

Adds the onboarding end-to-end test - #267

Merged
johnnyt merged 1 commit into
mainfrom
se-ou2d-onboarding-end-to-end
Nov 23, 2026
Merged

johnnyt merged 1 commit into
mainfrom
se-ou2d-onboarding-end-to-end

Conversation

@johnnyt

@johnnyt johnnyt commented Nov 23, 2026

Copy link
Copy Markdown
Member

What this adds

One durable test on SQLite, test/statifier_examples/library/onboarding_end_to_end_test.exs, that walks the branch library onboarding end to end. It adds no code and changes no fixture.

  • Two integrations picked: the catalogue sync and the card-reader setup. Each runs as a durable child of the onboarding execution, in the order picked; the second runs under the later pass's child id.
  • Back across the onboarding's own screens: from the pick back to the branch screen.
  • Back inside a setup: from the catalogue sync's schedule step back to its source step.
  • None across the boundary between the two: a setup's first step offers no Back and refuses a back request; the onboarding execution, resting on a running setup, is on no screen to go back from; and the closing screen after the loop of setups offers no Back and refuses one.
  • The Journey done with each child's outcome: the onboarding execution is completed, and each child's stored row is completed with the outcome done, the one the subchart block declares.
  • A checkpoint honoured: the onboarding fixtures carry no core.checkpoint, so the test builds a test-only copy of the card-reader setup with one after its location step and runs it as a Path of its own. Back is taken before the checkpoint, and after it Back is neither offered nor taken. The shipped setups are unchanged.
  • A misfit child refused: the shipped onboarding cannot misfit, since its allow-list admits only the three setups and each declares the block's one outcome. The test builds a test-only parent from the onboarding's pick and loop whose subchart declares synced. It is not the onboarding, so its child resolves from the shipped fixture list, where the library loan declares done. The refusal is child_outcome_undeclared, and no child execution exists.

What a restart is in this app

Nothing holds an execution between steps: every Signup.Journey call loads it from StatifierExamples.Persistence by its id. A restart is therefore a step taken by a process that has never seen the execution and holds only its id. Before each such step the test reads the stored execution row back and checks it is active, then takes the step from a fresh Task: every press of the onboarding, every read of its focus, and the checkpoint and misfit steps. It runs in the same node, so it proves that the steps need nothing but the store and the id, and not that the node itself was restarted.

Decisions this carries

  • Back in the setup documents through a plain returnable host step type, and none across the sub-path boundary: ruled by the operator, 2026-11-22.
  • The subchart outcome subset, with a misfit refused at child creation: ruled by the operator, 2026-11-19.
  • Answer routing to the newest child, with a named limit on stores that do not commit a child create and a parent step together: ruled by the operator, 2026-11-22. This app runs on SQLite, and the test claims nothing about whether that routing is exact here.

Sabotage

Each mutation below was applied, turned the test red on an assertion, and was reverted from a copy, byte-equal:

  • Onboarding.focus/1 always answering the onboarding execution itself.
  • Journey's Back reader answering true for every position.
  • Durable's subchart host always answering the shipped fixture list.
  • Durable's settled-position fold left out of a drive's reading.
  • statifier_blocks' outcome fit judging no child undeclared (a dependency mutation, recompiled for the test environment).
  • statifier_blocks' trail compiler placing no clear on a core.checkpoint (a dependency mutation, recompiled for the test environment).

Review

The pre-request review round read the test. Taken: every press now runs in a fresh process, the closing screen's Back is refused as well as not offered, Back before the checkpoint is exercised, the children are sorted by id before they are matched, and a comment was reworded.

Gate: full mix quality green on SQLite on the tree committed.

One durable test on SQLite walks the branch onboarding from its first
screen to its closing one: two integrations picked, Back between the
onboarding's own screens and inside a setup, none across the boundary
between them, each setup finishing as a child with the outcome done.
Every press is taken by a fresh process that holds only the execution
id, after the stored row is read back. A test-only card-reader Path
with a core.checkpoint shows Back taken before it and not offered after
it, and a test-only parent whose subchart declares an outcome its child
does not is refused before any child execution exists.

Refs: se-ou2d
@johnnyt
johnnyt merged commit 1271a84 into main Nov 23, 2026
4 checks passed
@johnnyt
johnnyt deleted the se-ou2d-onboarding-end-to-end branch November 23, 2026 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant