Skip to content

cli(test[load]): Snapshot multi-pane window layouts - #1121

Open
tony wants to merge 7 commits into
feat/vt-snapshotsfrom
feat/vt-window-snapshots
Open

tony wants to merge 7 commits into
feat/vt-snapshotsfrom
feat/vt-window-snapshots

Conversation

@tony

@tony tony commented Dec 1, 2026 •

Copy link
Copy Markdown
Member

Summary

  • Snapshot a 3-pane main-vertical workspace built by tmuxp load via Window.capture_vt().
  • Assert live control-mode parity via VtSessionObserver.snapshot_window() and assert_window_screen_box().
  • Snapshot zoomed window expansion and split-to-zoomed frame deltas with vt_snapshot.
  • Point [tool.uv.sources] at tmux-python/libtmux#939 and tmux-python/libvt#137.

Companion PR

Changes

  • pyproject.toml, uv.lock: point libtmux and libvt in [tool.uv.sources] at tmux-python/libtmux#939 and tmux-python/libvt#137 while preserving Python 3.11 markers.
  • tests/test_vt_snapshots.py, tests/__snapshots__/test_vt_snapshots.ambr: add test_cli_load_multipane_workspace_window_vt_snapshots covering main-vertical split borders, pane-border-status, CJK and SGR styles, live VtSessionObserver.snapshot_window parity, and zoomed window deltas.

Test plan

  • Formatting and lint checks pass via uv run ruff format . .github/scripts --check and uv run ruff check . .github/scripts
  • Static type checks pass on Python 3.11 and Python 3.15 via uv run --no-sync ty check --python-version 3.11 and uv run --no-sync ty check --python-version 3.15
  • Multi-pane workspace .ambr snapshots pass on Python 3.15 and skip cleanly on Python 3.11 via uv run pytest tests/test_vt_snapshots.py --reruns=0
  • Full tmux 3.3a to master matrix in CI

tony added 2 commits November 30, 2026 19:11
why: Exercise multi-pane window VT capture across tmuxp workspaces ahead
of the next libvt and libtmux releases.

what:
- Point [tool.uv.sources] at tmux-python/libtmux#939 and
  tmux-python/libvt#137 and refresh uv.lock while preserving Python 3.11
  compatibility
why: Verify that a multi-pane tmuxp YAML workspace renders split borders,
junctions, pane-border-status labels, CJK and SGR styles, zoom state,
and live control-mode parity into a single composited Snapshot.

what:
- Add test_cli_load_multipane_workspace_window_vt_snapshots exercising
  main-vertical layout, pane-border-status, Window.capture_vt,
  VtSessionObserver.snapshot_window, assert_window_screen_box, and zoom
  frame deltas with .ambr snapshots
@codecov

codecov Bot commented Dec 1, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 82.15%. Comparing base (5e86cd4) to head (7254e6f).

Additional details and impacted files
@@                Coverage Diff                 @@
##           feat/vt-snapshots    #1121   +/-   ##
==================================================
  Coverage              82.15%   82.15%           
==================================================
  Files                     31       31           
  Lines                   2791     2791           
  Branches                 525      525           
==================================================
  Hits                    2293     2293           
  Misses                   355      355           
  Partials                 143      143           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

why: tmux < 3.6 assigns odd remainder rows in layout_spread_cell to the
bottom split pane whereas tmux >= 3.6 assigns them to the top pane; an
8-row window gives 3 + 3 interior rows with zero remainder across all
tmux versions.

what:
- Size the dashboard PTY to 35x8 and refresh .ambr snapshots
- Point [tool.uv.sources] at the latest tmux-python/libtmux#939 tip
tony added 4 commits November 30, 2026 20:17
why:
Advance [tool.uv.sources] pins to the review-updated libvt #137
(c73745e2) and libtmux #939 (a9733bb7b) commits.

what:
- Repin libtmux to a9733bb7b99ab52a7709f74250f9381e271ab002
- Repin libvt to c73745e26f98df49b397761c88801d37b202996c
- Refresh uv.lock
why:
Advance [tool.uv.sources] pins to libvt #137 (ddcc6bd5) and libtmux #939
(f4f91f736).

what:
- Repin libtmux to f4f91f736ac09115ad8c4343b0cdccddaa6208ca
- Repin libvt to ddcc6bd5aac53e243ef226780d30134a9fae0851
- Refresh uv.lock
why:
Keep [tool.uv.sources] libtmux aligned with the latest libtmux #939
commit (601440a36).

what:
- Repin libtmux to 601440a36a2b293647c880a392b7d4bc1ce52872
- Refresh uv.lock
why:
libvt 0.0.1a5 is published on PyPI, so tmuxp only needs the libtmux #939
git source override until libtmux #939 lands.

what:
- Bump libvt[pytest,syrupy] requirement to >=0.0.1a5,<0.1
- Drop libvt from [tool.uv.sources] and repin libtmux to 6fc46db37
- Refresh uv.lock against PyPI libvt 0.0.1a5

This branch has not been deployed

No deployments
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