summaryrefslogtreecommitdiff
path: root/test/session.zig
Commit message (Collapse)AuthorAge
* test: Session.initShared's startup config lives in the session's arena, not ↵Gabriel Schneider7 days
| | | | | | | the constructor's frame: the core keeps the slice and a Restore applies it again, which read freed memory (an `init file line 1: unknown word` of 0xAA bytes in the log after every Restore in the suite) Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* tests: monkey and replay are modes of the T1 runner and snapshot.zig goes: ↵Gabriel Schneider8 days
| | | | | | | behaviour-test runs test/monkey9p.zig bare (its smoke), `-- --monkey <seeds>` drives an in-process session with test/monkey.zig's input (keys, leader bursts, the mouse, tiny resizes, over /kbdin, /mousein and Session.resize) hunting panics and hangs, `-- --replay` records each seed's sessions as a tape in memory and replays it (tape.replayBytes, replayMain's loop: three replicas and the dump), and `process-test -- --replay` records and replays the tty cases' real sessions as `zig build replay` did (with the addons it lacked, so images passes); the snap, snap-driver-test, monkey, monkey-test (it no longer compiled), replay and monkey-session steps, pardes-snap and build/snap.zig (now build/process.zig) go; checked: a counter outside the core bumped at the 40th update diverges every T1 seed and 89 of 103 old tapes, one bumped on terminal output diverges no T1 seed but 69 tty cases and 70 old tapes (why the tty replay stays), a panic on a window under 5x5 is found by the T1 monkey (seeds 1 8 17 20) and the old one (seed 13) Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* gui: a kind's pane (an image, a PDF) is watched again and shows its file as ↵Gabriel Schneider9 days
| | | | | | | it is now: Kind.open and a restored kind's pane emit its watch, which kinds #14 dropped with pdf_view, and a reload counts into its pictures' keys, since its kind numbers them afresh from each open and a window keeps a texture by key; the T1 session watches files as a host does (Session.filesChanged) and two behaviour cases pin it Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* kinds #43, the PDF kind in Zig: addons/pdf/pdf.zig replaces pdf.c over the ↵Gabriel Schneider10 days
| | | | | | | same pdf_bridge.c (its header translated by build.zig, Zig 0.17 having no @cImport), one place a pane (a page and how far down it, which where says and address takes) laid out by each view its own way (a view with pictures its own strip, rasters and thumb by its id, a view of glyphs the page's text layer), the view of the last input the one whose window's top the place follows; the pages' sizes, the page's text and its hits, and the search over every page on the lanes as jobs (rows streamed through found, a stale search cancelled, its first hit gone to as a Look of its first row went), the tick asking and laying out only, open's one parse and close kept on the loop (0.4 and 0.8 ms; a truncated file stays a refused Look); a band at most PA_RASTER_MAX; the static build reads the module's pardes_addon, exported only from the library Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* kinds #25, addons in Zig: src/kinds/addon.zig, over the translated header ↵Gabriel Schneider10 days
| | | | | | | and nothing of the core, makes a kind's pa_ops from a struct of the functions it has (its head from name, version, extensions and words; a public function of no kind's name a compile error), the pane's arena and a job's pa_out as std Allocators, typed keys, a Window to put text in, a Paint for the prefix and placements, tick's flags and a Deadline, dump and load as an extern struct's bytes in one line each, and body and ctl over a Writer; snake.zig and image.zig (stb_image in stb.c, static, beside any zstbi) replace snake.c and image.c with the same goldens, harness and perf cell, and addon-test runs their own zig tests Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* kinds #24, the addons as build steps: `zig build image` and `zig build pdf` ↵Gabriel Schneider10 days
| | | | | | | each build their library and install it in <prefix>/lib/pardes/addons (and ~/.local/lib/pardes/addons with the home install), `zig build addons` both, the default install the binaries alone and -Dmupdf gone, MuPDF compiled only for the pdf step and the tests that depend on its artifact as before (fetched at the first configure, which Zig runs alike for every step); install.typ, building.typ, reference.typ, shared-libs.md, the README and the changelog say so Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* kinds #20, their tests and docs: T1's sessions are a terminal without ↵Gabriel Schneider10 days
| | | | | | | graphics, so a PDF's key test is the base's text-layer one again beside the strip's (Session.graphics gives a frontend pictures), /addons says 2.2; pane cases for the hand over a link and a touchpad's fraction; reference.typ and the changelog say what a PDF does with and without graphics and what 2.2 added Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* kinds #14, the core's PDF code gone: pdf.zig and pdf_view.zig leave and ↵Gabriel Schneider10 days
| | | | | | | every pdf_enabled branch with them; look, Jump, Recent, dumps (one from before the addon opens as its pane), the watch, mouse, keys, the rail and the tag go through Kind for any kind's pane; test/pdf.zig's behaviours are T1 cases over 9P (addons_pdf.zig) and pane cases (a Shadow over a replica, a file changed under it), the harnesses load pdf.so by path Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* kinds #9, the core's image code gone: src/image.zig (558 lines) and the ↵Gabriel Schneider11 days
| | | | | | | static table go, so no kind is compiled in (Registry.init, Kind.image, compiledIn, `static` in /addons and "is compiled in" with them) and a test of the core's side of a kind's pane opens Kind.test_kind (a picture of one pixel, no library); a placement's fit (NativeGeometry, containGeometry) moves to surface.zig and a PDF's fit modes to pdf_view.zig; a terminal's kitty PNG decodes in TerminalImages.zig through wuffs as before, its downscale through stb_image_resize, the one part of zstbi the core keeps (stb_image patched out of it, the wuffs_images option, tag_image and image_exts gone); the image cases load the built image.so by path: test/panes.zig's and fs_namespace's through Addon.perform, T1 through Addon load (a new behaviour case: PNG, JPEG and PPM through 9P, the art words, a refused corrupt PNG, a dump's placeholder and its picture back, which replaces the decode unit test and ctl.zig's corrupt-image case), the snapshot, process and image harnesses by linking it into each session's data directory; images.snap unchanged Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* client #1, the views indexed: a view's share of the session is Pardes.View ↵Gabriel Schneider11 days
| | | | | | | (the ~42 fields views.fields named: size, cell metrics, columns, rects, focus, jumps, pointer, gestures, prefixes, frontend), one of Pardes.views[4] (null when closed), the live one views[live] through Pardes.view() (index field `view` renamed `live`); going into another view is the index plus the panes' shares, which stay swapped (park and unpark now move only Pane.pv); views.zig loses fields, Part over Pardes, Parked, kept, emptied and the session half of every copy, and a pane closing leaves every view's layout at once (views.gone, at the two places a slot is freed) instead of the serials each parked view kept; drawOne and within put the drawn view's own share back whole; the views are in the digest now (tape's per-field parts name views[k].field), so a fresh view's col_x/col_w default to zeros, not undefined; the dump keeps every open view in the core and the panes' shares of the others under `shares`; an image from before (live view as the core's own fields, the rest under `views`) loads them into views[] once; the ~2,400 references rewritten mechanically from the compiler's errors (p.active is p.view().active, `const v = p.view()` hoisted in 823 places), Kind.zig (4 lines) and addon_test.zig (3) among them, macos.zig by pattern (not compiled here); tape's watched host writes read the live view's frontend and active; perf.zig's accessor lines change its harness hash, the debug baselines re-keyed to it (their numbers the base's); no golden changes; gates: core-test 956/956 both, unit-test 1487/1488 tui and 1530/1531 gui, behaviour-test 248/248 both, pane-test 171/172, snap all 105 ok, process-test 0 of 37 failed tui, replicas ok Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* kinds #5, ABI 2 and the seam: src/kinds/pardes_addon.h is ABI 2 as ↵Gabriel Schneider11 days
| | | | | | | architecture §16.9 has it (pa_window 24 bytes and no art bytes, pa_placement 80 with at, from and dirty_y/dirty_h and no stride, pa_word 32 with no size and PA_WORD, tick(st, now_ns, flags) with PA_FOCUSED, PA_OK and the conventions, the dump and load rules, pa_put with attrs, pa_copy and PA_POD, whose fragment gcc -Werror refused as written and is ternaries here) and fake.c and image's table speak it; tick is called at its deadline and once after open, a taken key or click, a word, a job's answer, a load and a change of PA_FOCUSED (the pane has the keyboard in some view, its window focused), nextWake folds the deadlines, and a Debug build hashes the kind's allocations across paint and panics naming it; paint runs once a frame, the slot keeps its prefix and whether it placed a picture, the tag is that prefix, the core's art words when it did and the path, and a frame that changes it owes a step to lay the tag out again; Addon load and reload are an addon effect the host performs (memfd, BLAKE3, dlopen, the head checks and init, the bytes a process holds shared and counted) answered by an addon event carrying what the library brings as data, whose update does the collisions, the reload's validate-then-swap at a new generation and the waiting panes deterministically, while unload is the update's alone and lets the library go by effect; a kind's job is Effect.job run on the host's workers (host_io.KindJob: tui and gui on Io.concurrent, macOS and tests on the loop) answered by Event.job, stale generations dropped and a library closed after its last job; each core has its own Registry (16 kinds, their words, leaders and extensions, digested and dumped; their code a local side array a replica has none of), so a test session no longer unloads the world and Restore and -l keep the process's kinds; every call into a kind whose answer the core acts on is taped as an Outcome (its answer, refusal, message, Look, text pane) and the prefix a step reads is taped too, so a replica's core, which runs no kind's code, steps alike; a pane of a kind on a replica is a Shadow drawn from the authority's frames, painted for the peer's view and sent by Screens as row hashes with the rows that changed and each raster once a key (screen_state.Shadow), its keys going to the authority; the tail, reload and the Addon word and event are Addon.zig's, the slot's record dump.zig's, a tail word's run exec.zig's; --addon-test gains focus, blur, dump, body, ctl and the window line, its jobs done as a host does them; fake.out gains its window line, loses a body row once the tag carries the art words and lands FakeJob at once; tests rewritten: the image dump test (the replica-style load keeps the record), the Petscii/Palette/Ascii tag test in ctl.zig and test/panes.zig's image tag test (a picture decoded and shown first), fs_namespace's decode test (the job performed as a host would), Kind.zig's registry test and Addon.zig's crash-mark test, the addons suite's ABI numbers; new: a job under way across a reload (T1), a Shadow's frame codec, and a replica with no code for a kind showing its pane and passing its keys; gates: core-test 958/958 and behaviour-test 249/249 on both, unit-test 1490/1491 tui and 1533/1534 gui, pane-test 171/172, snap all 105 ok, process-test 0 of 37 failed on both, addon-test ok, hxdiff 19 and hxparity 6 mismatches by the base's names, hxgolf 0, replicas, gui-golden, monkey-gui, daemon.py main and window-clients, soak local pass, perf medium within 1% of the base Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* kinds #4, the fake addon and the addon test: addons/fake/fake.c is the ↵Gabriel Schneider11 days
| | | | | | | template, every function of src/kinds/pardes_addon.h in a few lines (a counter its keys, clicks, words, ticks and jobs move, a 2x2 picture, a body, an address, a ctl read, a dump and a load), built by the build with -Wall -Wextra -Werror four more ways for the loader to refuse (another ABI, no pardes_addon, a word that is the core's) or reload (no record of its own); `pardes --addon-test <lib> <script>` loads a library into a session of its own (80x24 unless `size`, `seed N` for the panes' seeds, jobs at once, a clock moved only by `tick` and `settle`, which ticks until the kind asks for no frame) and prints the pane's tag, cells and placements after each line of keys, clicks and words; the addon-test step (and behaviour-test) runs it over the fake against addons/fake/fake.out; T1 (test/behaviour/addons.zig): Addon load, /addons with its path, BLAKE3 and panes open, the words in /commands and Help, a word refused away from its kind, unload refused while a pane is open, a compiled-in kind not unloadable; a library of another ABI, one with no export, one whose word is the core's and a file that is no library each refused and listed with why; a pane of the kind taking keys, a click, a word, a job, its body and ctl read, Esc leaving it; a dump restored with the addon, without it (the placeholder, a word refused there), and the addon loaded again reopening it in place with its count; a reload refused for a half-built library with the old one running on, one taking the state across by dump and load, one with no record coming back from its words' last values; a Look by an addon's extension; a test session lets go of its addons at its end (the registry is the process's); gates on the head: core-test 961/961 and unit-test 1494/1495 tui, 1538/1539 gui, behaviour-test 250/250, pane-test 171/172, snap all 108 ok, process-test 0 of 37 failed on both, addon-test ok, hxdiff 19 and hxparity 6 mismatches (the base's), hxgolf 0, replicas, gui-golden, monkey-gui, daemon.py main and window-clients, soak local pass Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* settings #6, the cut through the public surface: a T1 case loads the user's ↵Gabriel Schneider11 days
| | | | | | | startup file (~/.config/pardes/init as it was on 2026-11-05, copied into the test, never read) and finds no init-file notice in /log and every value read back on the root ctl, the window's words as `# X unsupported` in a terminal's view, and a second refuses each of the fifteen cut words on the root ctl with the unknown-word refusal, finds none of them in /commands, and gives a startup file saying one a notice naming its line while the next line still applies (test/session.zig's initStartup); the cut is fifteen of the thirty-two words, Verbose, MessageLinger and DumpDir kept for the tests, harnesses and documented path that use them; a dump the base build wrote with every cut setting off its default Restores in this build; gates on the head: tui core-test 961/961, behaviour-test 242/242, unit-test 1478/1479, pane-test 171/172, snap all 105 scripts ok, process-test 0 of 37 failed, hxdiff 19 and hxparity 6 mismatches (the base's sets by name), hxgolf 0; gui behaviour-test 242/242, unit-test 1522/1523, process-test 0 of 37 failed, gui-golden 0 of 1 failed, monkey-gui 0 of 1 failed; daemon.py main and --window-clients ok; perf within 13% of the base on every medium gesture Co-Authored-By: Claude Fable 5.1 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* dumps: a Dump is a labelled entry of the state file (src/Db.zig, ↵Gabriel Schneider11 days
| | | | | | | architecture §14.3), one fsynced transaction: `dumps/<label>` holds the session as a database of its own, which the walk writes by field name into xitdb's maps (walk.Put: a struct a map keyed by its fields' names, a union a map of its one field, records a list, plain numbers one bytes value tagged with their kind and width, an enum its name, a number a uint or an int, an optional an absent key, a type with dumpWrite its bytes, a .blob text of 4 KiB and up its BLAKE3 hash) and another build reads by name (walk.Get: defaults, notes, a pane it cannot read left out, as the byte loader did), with the hashes of the texts it keeps once under `blobs/`, so an unchanged text is written once across dumps; labels are `pardes-<date>-<time>` (`-2` and on in one second), `last` names the newest, the newest 32 are kept and the texts no kept one names are dropped in the same transaction, and at a session's end the file is compacted into `pardes.xitdb.new` and renamed over once it is past twice what it holds plus 64 MiB (another session notices the new file by its inode); a dump travels as an image, a database in memory holding it alone, deterministic (std.Io.failing's zero ids, so the replay's fixpoint holds): what Dump hands its host, what `Dump export <path>` and $PARDES_DUMP write whole (the snapshot goldens' `Restore <path>` unchanged), what a Restore of a label is read into, what a handover carries (`handover-<seq>`), and what `-l` and `Restore <path>` read; Restore takes a label or a path (bare: this session's last dump, else the newest), a label the file keeps none of refused in words (`Restore: no dump labelled X`, asked of the authority as the closed panes are); `/dumps` lists them, `<label> <date> <size> <panes>`, the newest first; Upgrade commits `upgrade-<pid>` before the exec, its record naming the state file and the label (a record without one, an older build's, names its `.dump` file, read as before), and the label stays; the byte dump stays for the join, the closed panes and the old `.dump` files (dump.byteDump), and dump.outPath, uniqueIn and upgradePath go for dump.label; measured (Debug, a session with a 3.2 MB file and three scratch panes, 20 dumps): the image on the loop 64-66 ms (59 ms of it BLAKE3 of the file, 0.65 ms in ReleaseFast) where the byte dump was 0.7 ms, the commit 9-16 ms with its fsyncs where the file was written in 2, a Restore 1.8 ms to read and 11.4 to load, and the file 3.55 MB after the first dump and 379 KB a dump after it with the big text unchanged (3.58 MB a dump with it edited each time, as twenty `.dump` files would be); tests: dump.zig's 'two dumps in one second get names of their own' and 'a dump makes every directory missing on the way to its DumpDir' become Db.zig's 'two dumps with one label get labels of their own' and 'a Dump makes every directory missing on the way to its DumpDir, and the file there', 'a session read by name, field by field as another build reads it, is the same session' becomes 'a session's byte dump read by name...' beside the new 'a session's image, read by name as every load reads it, is the same session, and dumps to the same bytes again', two replica tests compare the join's stream with dump.byteDump, the Handover tests read the carried image, upgrade's record test carries a label, the root listing tests and the monkey list `dumps`, the behaviour suite gains five root-ctl tests (a Dump and Restore round trip through 9P with `/dumps` and the tag's word, a label kept none of refused in words, the 33rd dump dropping the first, an unchanged text written once across two dumps by the file's size, a killed Dump leaving the one before it whole), the test host performs a Dump's write and a Restore as a host does, the monkey lets go of its log follower at a Restore, and daemon.py's upgrade case finds the kept dump in `/dumps` Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* store: Recent is a value of the user's state file, `pardes.xitdb` in the ↵Gabriel Schneider11 days
| | | | | | | DumpDir (src/Db.zig: the xitdb database the architecture's §14 puts everything pardes keeps on disk in), which every session shares: read at a session's start (now after the startup config, whose DumpDir says where the file is) and again on use when the file's committed size has moved, written at the end of a step that changed it in one transaction under the file's lock, taken without waiting (busy, the next step tries again), another session's commit read and merged under this one's changes first; not fsynced, as the `recent` file was not (a xitdb commit costs 20 us without fsync and 5.2 ms with its two on this btrfs); a file there that is no database of pardes's is kept aside as `pardes.xitdb.broken` and a new one started; Store.zig keeps the closed panes alone (its file half goes: the path and its inode/size/mtime stamp, load, refresh, read, flush and write, and W4's one-time read of the old `store`, which comes back with the migration), Options.recent_path becomes Options.state (off, disk, memory), main.recentPath goes, a Restore's new core takes the old one's database, and the test host's sessions keep theirs in a `.memory` database, the same code; measured (Debug, 200 files listed): flush after an open 133-135 us (W4's file: 124), refresh after another session's write 239-247 us (198), refresh with nothing new 3 us (1), a session started on it 1144-1194 us (1214), and a Recent change adds 12,325 bytes to the file (its 12,089 bytes of lines and 236 of xitdb's); tests: Store.zig's four Recent tests become Db.zig's three (two windows sharing Recent through a busy lock, the newest 200, a file that is no database kept aside; the old store's migration test goes with that read), the closed-pane test keeps its second window on a state file in its DumpDir, the behaviour suite gains 'two sessions on one state file share Recent', and the process tests and the canary look for the state file where they looked for `recent` Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* test: T1 asks the language words' servers, the suite next-tests.md said was ↵Gabriel Schneider11 days
| | | | | | | missing: a Session made by initLanguage performs each lsp effect as a host does (host_io.Lsp, on the session's thread and at once; host_io is pub in the core for it), a .rs file's server the scripted one (test/lspmock.zig, built for the session's module as for the snapshot scripts), and test/behaviour/callstack.zig pins the guide's Call hierarchy through it: the tree +Callstack shows, and CallstackDepth bounding the walk Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* test: the 9P monkey at T1 and the agent driver's interaction checks at T2, ↵Gabriel Schneider12 days
| | | | | | | for the Python ports: test/monkey9p.zig (was test/monkey9p.py) drives an in-process Session with random 9P requests, every op drawn from the seed alone (panes, columns, stale serials and held files as tokens resolved when the op runs), so --seed/--steps replay a run, --only replays any subset of its steps and a failure shrinks by delta debugging over them; each run is a child of the program in a throwaway root (its HOME, XDG directories and dump), so a panic or a hang is a failure reported and shrunk like the rules' (one failure rule, close runs only line files, /index matching /pane, chunked reads equal whole, the log marker); the 9P engine's own refusals and OTRUNC's truncation made by the monkey, Session doing no effects; steps monkey-session and monkey-session-smoke, the smoke part of behaviour-test; Session's mky helpers walk, ask (a raw request answering errno, held or bytes) and ended; test/process/terminals.zig, three cases of test/agent_session_test.py (a prompt that settles, input shown and ^U taking the screen back; history past a screenful in the body; a raw-mode control byte through pty/data), the driver's own argument, output, timeout and cleanup checks left in Python; monkey9p.py deleted; each checked to fail against a break: serveFs not noting a pane file's err (one failure rule), noting it twice (one failure rule's upper bound), a msg beside a refused pane write (its msg clause), /pane leaving out serial 3 (index matching pane dirs), stagedReply skipping a byte past offset 0 on small reads (chunked equals whole), a panic in pty/run's write (a crash, shrunk 377 -> 3 ops), the root ctl taking an unknown word (the log marker), pty/data dropping a lone control byte (raw key), a 4 KiB terminal scrollback (history, raw key), pty/data dropping a write's last byte (all three terminal cases) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
*-. merge round 2 of the behavioural-test migration (ctl 62, pane 27, core 21: ↵Gabriel Schneider12 days
|\ \ | | | | | | | | | | | | | | | | | | 110 tests moved, effect-dependent ones left where they are as the user said), onto the tag-mode and process-runner line: the moved tests that clicked a tag and typed now type i first, a sweep's lit cells include the caret's in normal mode, the placement test's screen widened so a tag with a long temporary path stays one row wherever the checkout is; 216 behavioural tests; behaviour, fs-unit, core, pane and process tests, the gui build and all 113 snap scripts pass; docs/next-tests.md's progress Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
| | * test: three of src/pardes.zig's tests through the 9P tree alone: in ↵Gabriel Schneider12 days
| |/ |/| | | | | | | | | | | test/behaviour/columns_and_tags.zig a column tag lighting the word under the mouse, taking the caret where pressed, sweeping three cells in the selection's colour, typed at its caret (Home, Help) and scrolling its text from the column's edge, never its caret (each column); in test/behaviour/mouse.zig a click on either half of a wide character landing before it in the text (dot) and on a tag's path (a name drafted, Right stepping a grapheme, two cells then one), a two-byte λ typed in a tag and taken out by one backspace, and a sweep pressed on the line numbers taking only the text (unlit numbers, a Look in it finding its next place, a chord cutting it); Session's bg (a cell's background from /screen's styles); each checked to fail against a break (no tag hover, the header scrolled one cell too far, byteAtDisplay rounding a wide glyph's second half past it, Right stepping a byte in insert, the three clamps that keep a sweep's first row off the line numbers dropped) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
| * test: syntax colours and Save's prompt through the 9P tree alone, ↵Gabriel Schneider12 days
|/ | | | | | | Session.styles added (each cell's style as /screen draws it, as JSON text): in test/behaviour/settings.zig Colors off drawing a source plain and on again colouring its fn and if, the layout as it was, an edit made while off included, and SyntaxBold keywords coloured and bold in every row a detached session's size grows a pane into; in panes.zig a rename colouring a source in its new name's language, its text unchanged; in keys.zig Save's prompt on a scratch made by New from a file's pane starting from its directory, one slash after it (/dír space/, and / alone); each checked to fail against a break (the Colors toggle not marking syntax dirty, the painted stretch four rows from the scroll, a rename not marking syntax dirty, the prompt's slash always added, the prompt from the session's directory); test/panes.zig's Colors and growing tests and pane.zig's cached-syntax rename test deleted, and the Save prompt test trimmed to an owned directory ending in a slash or empty (a shell's, T2) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
*---. merge the four behavioural-test migrations (ninep, panes, core, pdf): 101 ↵Gabriel Schneider13 days
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | tests moved off internals onto Session, each checked against a break by its migrator and a sample by a reviewer; test/behaviour/ holds 108; Session's area methods spliced in (one where and the optional cursor kept, its callers taking .?), helpers that clashed renamed; docs/next-tests.md's progress table, what the M left need, and the traps found in Session Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
| | | * test: the pdf area's behavioural tests skip in a build without PDFs ↵Gabriel Schneider13 days
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (-Dmupdf=false), as the old ones did: Session.lookFile of a .pdf skips the test when /commands has no PdfTint (seven failed there before, now eight skip); and a look at a page past the last of a PDF that is not open checks its miss in the log (other.pdf has no page 999), not /index alone; checked to fail against a break (Pdf.openPane's NoSuchPage answered with no miss), which passed the test before Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
| | | * test: three of test/pdf.zig's look tests through the 9P tree alone ↵Gabriel Schneider13 days
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (test/behaviour/look_and_exec): `:N` on a PDF from its look, the root's and `@pN:N` (the page read from its tag's [P/N]), its misses in the log (no page 0, no search hit, no text to address, one past the last); a page past the last a miss, open or not, opening nothing (/index); a +PdfSections row's page checked against the outline; Session's lookFile and pdfPage; each checked to fail against a break (a PDF look turning to page 1 always, an open PDF's past-last page check dropped, Pdf.openPane taking .last for .refuse, the sections row's page check dropped) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
| | * | test: five more of src/pardes.zig's tests through the 9P tree alone ↵Gabriel Schneider13 days
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (test/behaviour/placement, panes, terminals, modes): an empty active column taking a look from another column's text whole, Collapse folding a pane to its tag (no text drawn, no cursor, its tag still typed into) and restoring it, a pane its whole text fits in never scrolled for a margin, Togglettymode and Ctrl-B sharing the mode's transitions from the body or the tag and a text pane refusing it, Esc back into a file keeping its view where a look's :N centres; Session's where (the first place /screen draws a text); each checked to fail against a break (acmeColumn ignoring the active column, toggleCollapse never unfolding, the scroll margin clamped at the last line alone, toggleTty leaving the tag the keyboard, Last landing centred) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
| | * | test: eleven more of src/pardes.zig's tests through the 9P tree alone ↵Gabriel Schneider13 days
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (test/behaviour/columns_and_tags, modes, tags, panes): a click past a column tag's text typing after it, a newline there a space and a long tag scrolled to its caret, Enter and Tab in a tag running the word under the cursor, Esc alternating two panes of a kind, Esc out of a column or the workspace tag, Shift-Esc out of every mode, a name typed into the tag's path pending past Esc, an unsaved file's tag its name alone, a question ended in the log when its pane closes, focus on a closed pane to the one taking its place; Session's cursor (/screen's); each checked to fail against a break (flatten keeping newlines, the header drawn unscrolled, Enter in a header a Look, Esc in normal mode not running Last, Esc in a header not leaving it, Shift-Esc leaving insert on, the first Esc on a drafted name dropping it, a dirty tag marked ' *', del_side left out of noteRetire's answer, removeColumn's focus to any pane) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
| | * | test: eight of src/pardes.zig's tests through the 9P tree alone ↵Gabriel Schneider13 days
| | |/ | | | | | | | | | | | | | | | | | | (test/behaviour/columns_and_tags, look_and_exec): Joincol folding a column into its right neighbour and refused with none, Newcol's empty column with its tag focused filled by the next Tty, a column's exec acting on that column and a pane's Delcol on its own, a column's last pane closed leaving it empty and Delcol taking it, a column's tag following it through Newcol and Joincol, Delcol on the last column leaving the window typed into, New in no pane's tag nor the workspace's, a look that finds nothing in the log; Session's columns and column (/layout as column:panes); each checked to fail against a break (joinCol inert, joinCol keeping the left tag, acmeColumn ignoring the active column, a scratch ignoring exec_column, no enterHeader for an emptied column, removeColumn refusing the last, New in a file pane's tail, missed logging nothing) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
| * | test: test/panes.zig's eight tag-navigation tests through the 9P tree alone ↵Gabriel Schneider13 days
| | | | | | | | | | | | | | | | | | | | | (test/behaviour/tags.zig, guide.typ's Tags): s and S in a tag selecting its own text (a c changing both S's) while / searches the body (its +Search lists the match), ms and md read back from the tag file, the path the keyboard reaches, yanks (pasted into the body) and cannot edit, a name drafted by typing into it, a tag remembering its cursor across panes and a prompt, starting on Save and moved by a click, Tab and Enter from a tag giving the body the keyboard back (a Save counted, the next keys typed into the body), the cursor after a rename and a shorter tag, window keys from a tag, a tag's normal and insert modes; Session.cursor (the screen's cursor cell, read from /screen) and Session.replace (a write truncating first, a shell's >); each checked to fail against a break (a tag's s prompt answering for the body, ms closing a character early, a tag edit into the path taken, enterTag always landing on Save, a truncated tag's cursor left at 0, the execute key leaving the tag the keyboard, a tag the keyboard left keeping it) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
| * | test: five of test/panes.zig's mouse tests through the 9P tree alone ↵Gabriel Schneider13 days
| |/ | | | | | | | | | | | | (test/behaviour/mouse.zig, guide.typ's The mouse): a double-click's word, bracketed, quoted and line selections (read from sel) and in a tag (yanked and pasted into the body), a B1 chord's cut and paste one undo step (one Undo gives back the text before the cut), a click past a line's or the file's end and on a tab's or a wide glyph's second cell (dot, then the Z insert types), a B1 sweep over several lines a stream in a body and a tag (a B1-B2 cut of it); Session.where, the screen cell text is first drawn at; each checked to fail against a break (double-click selecting nothing, chord_hold no longer folding the chord's undo steps, the click clamp a column short of the line's end, every grapheme one cell wide to a click, a sweep's start at the lesser of its two columns) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* / test: four more of src/ninep/ctl.zig's tests through the 9P tree alone, on ↵Gabriel Schneider13 days
|/ | | | | | | opens a test holds: Session's hold, readFid, writeFid and clunk (and truncate, readAt and stat for the pane files' tests next), an open kept as an event reader or a lock holder keeps one; lock and unlock on one ctl open against another (test/behaviour/panes), the event reader taking a pane's look, exec and tag clicks and acting on them written back, a refused Del written back EIO (new test/behaviour/event), /pager answering on the open that asked (other_files); each checked to fail against a break: another open's lock taken, a reader never taking a click, an event write-back's failure not captured, /pager answering the session's last result; the old pager test's two-line write refused is a handle-less write's alone (an open takes the second line as the text) and is gone Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* test: four more of src/ninep/ctl.zig's tests through the 9P tree alone ↵Gabriel Schneider13 days
| | | | | | | (test/behaviour/look_and_exec, columns_and_tags, root_ctl): a look's leading blanks and exec's trim, a bare :N look from a pane's look, the root's and an event write-back (dot read from the dot file), a look after Newcol (the column read from /layout), size of a detached session (the screen read from /screen); Session's range and detach; each checked to fail against a break (a look's blanks trimmed, size taking a screen too small for its panes) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge
* test: the behaviour-test step and test/session.zig, T1 of ↵Gabriel Schneider13 days
docs/next-tests.md: a Session drives the core as a 9P client does (walk by path, open, read or write, clunk, held lines run at the clunk as src/9p_io.zig runs them), the core opaque and the step's module importing session alone, so a behavioural test cannot reach past the 9P tree; keys (kbdin), click (on text found on /screen, mousein), screen, focused, refused and the refusal's words; test/behaviour/{other_files,panes,edit}.zig, a file a section of the reference: kbdin and mousein, a collapsed pane's ctl, name's leading blank, Putall, Edit blocks, moved out of src/ninep/ctl.zig (an Edit block left open now checked as a client sees it, an err in the log at its clunk), each checked to fail against a break (collapsed left off the ctl read, Putall saving nothing); the plan doc says the layout, the decisions and the progress Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge