Skip to content

test: expect the contents spine's 7px section markers that #6113 chose - #6184

Merged
leaf-agent merged 2 commits into
mainfrom
fix/issue-6175
Nov 16, 2026
Merged

leaf-agent merged 2 commits into
mainfrom
fix/issue-6175

Conversation

@leaf-agent

@leaf-agent leaf-agent commented Nov 16, 2026 •

Copy link
Copy Markdown
Collaborator

#6113 deliberately widened a section's marker on the contents map's spine from 6px to 7px, so every marker is an odd number of pixels across and centres on the 1px spine instead of standing half a pixel off it. test_a_contents_spine_maps_the_document_until_the_user_enters_it, a nightly journey that #6113's own CI didn't run, still expected 6px and has failed since. This updates its expected widths to 7px; its other assertions, including that every marker centres on the spine, are unchanged. It also corrects the toc.css header, which still described the top-level markers as 6px rings. Nothing on screen changes beyond what #6113 already shipped.

Run by node id, the journey fails on main with ['9px', '7px', '3px', '3px', '7px', '7px', '7px'] == ['9px', '6px', ...] and passes with this change.

Closes #6175 — automated triage

#6113 widened a section's marker on the contents spine from 6px to 7px so every marker is an odd number of pixels across and centres on the 1px spine. The contents-spine journey still expected 6px, and has failed since. It now expects 7px; the behavior it protects, each marker's size and centring on the spine, is unchanged.

Closes #6175

@leaf-agent leaf-agent left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The header of packages/default/styles/toc.css still says "The title and top-level sections use 9px and 6px rings", but #6113 widened the top-level marker to 7px (lf-toc li[data-lf-depth="0"]::before { --lf-toc-dot: 7px; }), the width this test now expects. The header records the module's product decisions, so a reader trusting it would put back the even width that stands off the spine. I'll push a one-line fix to the header so it says 7px.

@leaf-agent
leaf-agent merged commit 462d824 into main Nov 16, 2026
6 of 7 checks passed
@leaf-agent
leaf-agent deleted the fix/issue-6175 branch November 16, 2026 17:30
leaf-agent added a commit that referenced this pull request Nov 16, 2026
… last frame (#6194)

`test_a_display_widget_draws_on_a_page_without_leaf` failed on #6184's
CI ([run
43915527596](https://github.com/max-sixty/leaf/actions/runs/43915527596))
with `assert 299.5 == 300`. #6184 didn't cause it: it changed only a CSS
comment and a journey's expected widths. The cause is in the test.
`lf-motion`'s clock shows `Math.round(time)`, so it already reads "300
ms" when the clock stands at 299.5 ms, one frame before playback ends.
The test waited on that text and then read the last drawn frame. It now
waits for the transport's button to say Play again, which `#tick` does
when it pauses at the duration, in the same task that draws the final
frame. The assertions themselves are unchanged, and so is the widget.

Verified locally: the test passes alone, and five more times with six
busy loops starving the 4-core runner of CPU. The failure needs a frame
to land within half a millisecond of the end, so it didn't reproduce
before the change either; the evidence for the cause is the CI failure
together with the rounding in `packages/motion/widgets/motion-view.js`.

Co-authored-by: leaf-agent <[email protected]>
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.

test_a_contents_spine_maps_the_document_until_the_user_enters_it: section markers are 7px, not 6px, since #6113

1 participant