aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authoruser <user@clank>2026-08-19 13:47:10 +0200
committeruser <user@clank>2026-08-19 13:47:10 +0200
commitffaf9ff9db77573612317882b96158b5c7ba9655 (patch)
treeb8371eaa03be35bd7ba23e70c7ae8421c0387440 /tests
parentslosh: defaults most people can live in, said by shaders (diff)
downloadslosh-ffaf9ff9db77573612317882b96158b5c7ba9655.tar.gz
slosh-ffaf9ff9db77573612317882b96158b5c7ba9655.tar.xz
slosh-ffaf9ff9db77573612317882b96158b5c7ba9655.zip
slosh: split app.c into five units, mechanically
app.c was 7k lines wearing section markers; now the markers are files, cut exactly along them, no behaviour change: app.c the session core: config in force, pane and tab lifecycle, walking, input routing, introspection app_layout.c layout, tree edits, resizing, equalising, rotating, focus app_session.c layout files, checking, workspaces, dumping a session app_draw.c drawing, the shader passes, kitty graphics app_ui.c the finder, modals, the palette, the project picker, renaming include/app_internal.h carries what the five share: the tree/tab/app structs, CFG and the palette macros, and the 50-odd formerly static functions the cut made cross-unit, declared where they are defined. They keep their names; only the five units see the header. One test moved with the code: test_portable_layouts' staleness check greps the source for the layouts section, which now lives in app_session.c. Mechanical, so blame for anything in the four new files continues in app.c before this commit.
Diffstat (limited to 'tests')
-rw-r--r--tests/test_portable_layouts.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/test_portable_layouts.py b/tests/test_portable_layouts.py
index 02c43d2..5b3ccc0 100644
--- a/tests/test_portable_layouts.py
+++ b/tests/test_portable_layouts.py
@@ -338,9 +338,11 @@ def test_a_syntax_error_in_a_layout_is_reported_as_the_layout_it_is():
def test_the_layout_property_lists_cannot_go_stale():
"""The checker's lists and build_pane's reads are two copies of one schema, and
the copy that silently gets it wrong is the one that only complains."""
- src = (pathlib.Path(__file__).resolve().parent.parent / "src" / "app.c").read_text()
+ src = (
+ pathlib.Path(__file__).resolve().parent.parent / "src" / "app_session.c"
+ ).read_text()
start = src.index("/* ---- layouts ---")
- end = src.index("/* ---- resizing and reordering")
+ end = src.index("/* ---- dumping")
section = src[start:end]
import re