summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/fs.py2
-rw-r--r--test/lspbench.zig1
-rw-r--r--test/snapshot.zig2
-rw-r--r--test/snapshots/lsp.golden5
-rw-r--r--test/snapshots/lsp.snap10
-rw-r--r--test/snapshots/lspcomplete.golden20
-rw-r--r--test/snapshots/lspcomplete.snap21
-rw-r--r--test/snapshots/lspcompletemoved.golden2
-rw-r--r--test/snapshots/lspdebug.golden2
-rw-r--r--test/snapshots/lspdebug.snap23
-rw-r--r--test/snapshots/lsprelpath.golden120
-rw-r--r--test/snapshots/lsprelpath.snap34
12 files changed, 117 insertions, 125 deletions
diff --git a/test/fs.py b/test/fs.py
index 06643385..6f1165e5 100644
--- a/test/fs.py
+++ b/test/fs.py
@@ -1327,7 +1327,7 @@ def test(binary, quic=False):
time.sleep(.005)
assert len(matches) == 1, matches
result = client.read(f'/pane/{matches[0]}/body')
- assert result.startswith(b'backend: zls-inproc+lsp-client\n'), result
+ assert result.startswith(b'backend: lsp-client\n'), result
assert b'protocol servers (lsp-client):' in result, result
assert client.read('/pane/1/body') == b'initial\n'
assert '+Lsp' in ''.join(cell[0] for cell in client.screen()['cells'])
diff --git a/test/lspbench.zig b/test/lspbench.zig
index 36969680..e094ed69 100644
--- a/test/lspbench.zig
+++ b/test/lspbench.zig
@@ -40,7 +40,6 @@ const anchors = [_]Anchor{
.{ .file = "src/lsp/lsp.zig", .needle = "pub const Kind", .at = 11, .kind = .workspace_symbols, .expect = "" },
.{ .file = "test/lspfixture/broken.zig", .needle = "unused_local", .at = 0, .kind = .workspace_diagnostics, .expect = "broken.zig" },
.{ .file = "src/lsp/lsp.zig", .needle = "std.mem.count(u8", .at = 4, .kind = .completion, .expect = "std.zig" },
- .{ .file = "src/lsp/lsp_zls.zig", .needle = ".declaration => try rowForToken", .at = 1, .kind = .completion, .expect = "type_definition" },
.{ .file = "src/normal.zig", .needle = ".definition => .definition,", .at = 1, .kind = .completion, .expect = "" },
// The repeated name proves the result includes the declaration, not just the cursor line.
.{ .file = "test/lspfixture/dotcomplete.zig", .needle = "return switch (s) {\n .", .at = 29, .kind = .completion, .expect = "verdigris verdigris," },
diff --git a/test/snapshot.zig b/test/snapshot.zig
index 0514d8d8..a176da7a 100644
--- a/test/snapshot.zig
+++ b/test/snapshot.zig
@@ -580,7 +580,7 @@ fn runScript(arena: std.mem.Allocator, exe_z: [:0]const u8, script_path: []const
_ = setenv("LC_ALL", "C", 1);
// a wall clock cannot live in a golden; everything that would print one
// prints fixed characters instead when this is set — the lsp introspection
- // views' durations (lsp_zls.zig hideTime) and the transient message row's
+ // views' durations and the transient message row's
// time of day (message.zig stamp)
_ = setenv("PARDES_NOTIME", "1", 1);
// A virtual core clock: animation moves a frame per timed-out wait,
diff --git a/test/snapshots/lsp.golden b/test/snapshots/lsp.golden
index be0090fb..88291324 100644
--- a/test/snapshots/lsp.golden
+++ b/test/snapshots/lsp.golden
@@ -14,6 +14,7 @@
| 10
== snap cursor grid=120x41 cursor=17,10
== snap definition grid=120x41 cursor=15,5
+|3: 1 const std = @import("std"); --:--:-- lsp zls ready — /tmp/pardes-snap/lsp/cwd
== snap hover grid=120x41 cursor=15,5
|3: 1 const std = @import("std"); Hover
|12: /tmp/pardes-snap/lsp/cwd/+Hover Save Tty Collapse Del
@@ -26,9 +27,9 @@
|16: 1 a.zig:1:7-9
|17: 2 std
|18: 3 a.zig:3:4-9
-|19: 4 helper fn helper(x: u32) u32
+|19: 4 helper
|20: 5 a.zig:7:8-11
-|21: 6 main fn main() void
+|21: 6 main
|22: 7
== snap step grid=120x41 cursor=15,3
|3: 1 const std = @import("std");
diff --git a/test/snapshots/lsp.snap b/test/snapshots/lsp.snap
index b40484ee..97fcf7ed 100644
--- a/test/snapshots/lsp.snap
+++ b/test/snapshots/lsp.snap
@@ -1,11 +1,11 @@
# Language intelligence end to end: the helix keymap, the async round trip and
# the two dispositions of an answer.
#
-# The backend behind the seam here is ZLS linked in as a LIBRARY
-# (src/lsp_zls.zig) — no server process, no JSON-RPC — so `gd` is a function
-# call on a worker thread whose result comes back as an ordinary event, the
-# same shape a pty read already had. Nothing in this script knows that: it
-# presses keys and reads the grid, which is the point of the seam.
+# The backend behind the seam here is zls, run as a child process by the
+# protocol client (it must be on PATH): `gd` is a request on a worker thread
+# whose result comes back as an ordinary event, the same shape a pty read
+# already had. Nothing in this script knows that: it presses keys and reads
+# the grid, which is the point of the seam.
#
# a.zig is deliberately self-contained — a definition, a call site, and not one
# symbol from std — so these goldens do not encode this machine's stdlib
diff --git a/test/snapshots/lspcomplete.golden b/test/snapshots/lspcomplete.golden
index 0b29034f..77f844ac 100644
--- a/test/snapshots/lspcomplete.golden
+++ b/test/snapshots/lspcomplete.golden
@@ -19,16 +19,18 @@
|2: ^* /tmp/pardes-snap/lspcomplete/cwd/a.zig Save Tty Collapse Del TreeContext
|12: 10 }
== snap commentindent grid=120x41 cursor=19,14
+|3: 1 const Shade = enum { --:--:-- lsp zls ready — /tmp/pardes-snap/lspcomplete/cwd
|14: 12 // note. see below
== snap athedot grid=120x41 cursor=16,10
+|3: 1 const Shade = enum {
|10: 8 .
== snap completion grid=120x41 cursor=16,10
|15: /tmp/pardes-snap/lspcomplete/cwd/+Search Save Tty Collapse Del
-|16: 1 a.zig:2:5-13 verdigris verdigris,
-|17: 2 a.zig:3:5-12 cinnabar cinnabar,
+|16: 1 a.zig:8:10 verdigris
+|17: 2 a.zig:8:10 cinnabar
|18: 3
== snap refill grid=120x41 cursor=16,10
-== snap step grid=120x41 cursor=19,4
+== snap step grid=120x41 cursor=16,10
|2: * /tmp/pardes-snap/lspcomplete/cwd/a.zig Save Tty Collapse Del TreeContext
== snap txtindent grid=120x41 cursor=15,3
|Newcol Joincol Find Grep Help Changelog Tutor Dump NextColor Debug Exit
@@ -40,7 +42,7 @@
|Newcol Joincol Find Grep Help Changelog Tutor Dump NextColor Debug Exit
| New Tty Find Grep Joincol Delcol
|^* /tmp/pardes-snap/lspcomplete/cwd/c.zig Save Tty Collapse Del TreeContext
-| 1 const Shade = enum {
+| 1 const Shade = enum { --:--:-- lsp zls ready — /tmp/pardes-snap/lspcomplete/cwd
| 2 verdigris,
| 3 cinnabar,
| 4 };
@@ -49,14 +51,14 @@
| 7 const z: Shade = .
| 8 }
| /tmp/pardes-snap/lspcomplete/cwd/+Search Save Tty Collapse Del
-| 1 c.zig:2:5-13 verdigris verdigris,
-| 2 c.zig:3:5-12 cinnabar cinnabar,
+| 1 c.zig:7:23 verdigris Shade
+| 2 c.zig:7:23 cinnabar Shade
| 3
== snap nobrace grid=100x19 cursor=16,10
|Newcol Joincol Find Grep Help Changelog Tutor Dump NextColor Debug Exit
| New Tty Find Grep Joincol Delcol
|^* /tmp/pardes-snap/lspcomplete/cwd/d.zig Save Tty Collapse Del TreeContext
-| 1 const Shade = enum {
+| 1 const Shade = enum { --:--:-- lsp zls ready — /tmp/pardes-snap/lspcomplete/cwd
| 2 verdigris,
| 3 cinnabar,
| 4 };
@@ -64,6 +66,6 @@
| 6 pub fn nobrace(s: Shade) void {
| 7 switch (s) {
| /tmp/pardes-snap/lspcomplete/cwd/+Search Save Tty Collapse Del
-| 1 d.zig:2:5-13 verdigris verdigris,
-| 2 d.zig:3:5-12 cinnabar cinnabar,
+| 1 d.zig:8:10 verdigris
+| 2 d.zig:8:10 cinnabar
| 3
diff --git a/test/snapshots/lspcomplete.snap b/test/snapshots/lspcomplete.snap
index 53ce7ef9..d9e165a1 100644
--- a/test/snapshots/lspcomplete.snap
+++ b/test/snapshots/lspcomplete.snap
@@ -1,6 +1,7 @@
-# Tab after a dot in insert mode: "what could go here, and where is each of
-# those defined". The answer is a `+Search` buffer of DEFINITION rows, the same
-# rows `gr` fills it with — nothing is inserted and nothing pops up.
+# Tab after a dot in insert mode: "what could go here". The answer is a
+# `+Search` buffer of zls's candidates, one row each at the cursor (a
+# completion item names no declaration) — nothing is inserted and nothing pops
+# up.
#
# a.zig is std-free for the reason lsp.snap's is: these goldens must not encode
# this machine's stdlib version or its install path. Its enum members are
@@ -58,12 +59,10 @@ text .
stable 400 5000
snap athedot
key tab
-# The row that proves it: `a.zig:2:` is `verdigris`'s own declaration line.
-# The cursor is on line 8; nothing about line 2 is reachable from the text
-# under it, so this row can only have come from resolving the switch's
-# condition to `Shade` and asking `Shade` what it declares. Line 8 still reads
-# `.` and nothing else — a completion INSERTS NOTHING.
-wait 15000 a.zig:2:
+# The rows that prove it: `verdigris` and `cinnabar` can only have come from
+# resolving the switch's condition to `Shade` and asking what it declares.
+# Line 8 still reads `.` and nothing else — a completion INSERTS NOTHING.
+wait 15000 +Search
stable 700 15000
snap completion
# Two more Tabs. Every one of them answers, and every answer REFILLS the one
@@ -128,7 +127,7 @@ key end
text .
stable 400 5000
key tab
-wait 15000 c.zig:2:
+wait 15000 +Search
stable 700 15000
snap nosemi
# ...and a construct still hanging OPEN. The switch has no closing brace at
@@ -149,6 +148,6 @@ key end
text .
stable 400 5000
key tab
-wait 15000 d.zig:2:
+wait 15000 +Search
stable 700 15000
snap nobrace
diff --git a/test/snapshots/lspcompletemoved.golden b/test/snapshots/lspcompletemoved.golden
index a033ed56..c6db1812 100644
--- a/test/snapshots/lspcompletemoved.golden
+++ b/test/snapshots/lspcompletemoved.golden
@@ -2,7 +2,7 @@
|Newcol Joincol Find Grep Help Changelog Tutor Dump NextColor Debug Exit
| New Tty Find Grep Joincol Delcol
|^* /tmp/pardes-snap/lspcompletemoved/cwd/a.zig Save Tty Collapse Del TreeContext
-| 1 const Shade = enum {
+| 1 const Shade = enum { --:--:-- lsp zls ready — /tmp/pardes-snap/lspcompletemoved/cwd
| 2 verdigris,
| 3 cinnabar,
| 4 };
diff --git a/test/snapshots/lspdebug.golden b/test/snapshots/lspdebug.golden
index cf2eb097..1db8b0b9 100644
--- a/test/snapshots/lspdebug.golden
+++ b/test/snapshots/lspdebug.golden
@@ -14,6 +14,8 @@
| 10 }
| 11
== snap ctrlclick grid=120x45 cursor=15,5
+|3: 1 const std = @import("std"); --:--:-- lsp zls ready — /tmp/pardes-snap/lspdebug/cwd
== snap plainclick grid=120x45 cursor=21,10
+|3: 1 const std = @import("std");
== snap why-closed grid=120x45 cursor=7,5
== snap report-closed grid=120x45 cursor=7,5
diff --git a/test/snapshots/lspdebug.snap b/test/snapshots/lspdebug.snap
index ab330a76..3aca07cc 100644
--- a/test/snapshots/lspdebug.snap
+++ b/test/snapshots/lspdebug.snap
@@ -21,10 +21,8 @@ snap plainclick
text 3gg1g|
stable 400 10000
key space l w
-wait 10000 parsed 122 bytes, 0 syntax error(s)
-wait 10000 position context: .empty
-wait 10000 STOP: nothing to resolve
-wait 10000 0 row(s)
+wait 10000 lsp explain — the definition query
+wait 10000 row(s)
key space w j
key space d
stable 700 15000
@@ -32,20 +30,15 @@ snap why-closed
# Check the report's answers, not installed compiler paths or dependency counts.
key space l i
-wait 10000 backend: zls-inproc+lsp-client
-wait 10000 compiled in
-wait 10000 [OK]
-wait 10000 offsets: utf-8
+wait 10000 backend: lsp-client
+wait 10000 protocol servers (lsp-client):
+wait 10000 zls
key space w j
key /
-text last queries
+text client queries
key enter
-wait 10000 last queries
-wait 10000 definition z.zig
-# The results pane the search opened takes the bottom half, which leaves the
-# report one row short of its second query: step the cursor past it.
-key j j j
-wait 10000 explain z.zig
+wait 10000 client queries
+wait 10000 definition
# the report sits between the source and the results, so Del asks where its
# rows go: k, back to the source above
key space d
diff --git a/test/snapshots/lsprelpath.golden b/test/snapshots/lsprelpath.golden
index 201f6dd4..80064f00 100644
--- a/test/snapshots/lsprelpath.golden
+++ b/test/snapshots/lsprelpath.golden
@@ -1,48 +1,49 @@
-== snap absrow grid=100x35 cursor=16,7
+== snap absrow grid=100x35 cursor=21,16
|Newcol Joincol Find Grep Help Changelog Tutor Dump NextColor Debug Exit
| New Tty Find Grep Joincol Delcol
-|^* /tmp/pardes-snap/lsprelpath/cwd/sub/parent.zig Save Tty Collapse Del TreeContext
-| 1 const shade = @import("../shade.zig");
+| /tmp/pardes-snap/lsprelpath/cwd/sub/parent.zig Save Tty Collapse Del TreeContext
+| 1 const shade = @import("../shad --:--:-- lsp zls ready — /tmp/pardes-snap/lsprelpath/cwd/sub
| 2
| 3 pub fn pick(s: shade.Shade) u8 {
| 4 return switch (s) {
-| 5 .
+| 5
| 6 };
| 7 }
-| /tmp/pardes-snap/lsprelpath/cwd/sub/+Search Save Tty Collapse Del
-| 1 /tmp/pardes-snap/lsprelpath/cwd/shade.zig:2:5-13 verdigris verdigris,
-| 2 /tmp/pardes-snap/lsprelpath/cwd/shade.zig:3:5-12 cinnabar cinnabar,
-| 3
-== snap abslook grid=100x35 cursor=19,15
-|2: * /tmp/pardes-snap/lsprelpath/cwd/sub/parent.zig Save Tty Collapse Del TreeContext
-|13: /tmp/pardes-snap/lsprelpath/cwd/shade.zig Save Tty Collapse Del TreeContext
-|14: 1 pub const Shade = enum {
-|15: 2 verdigris,
-|16: 3 cinnabar,
-|17: 4 };
-|18: 5
+| /tmp/pardes-snap/lsprelpath/cwd/sub/+Search Save Tty Collapse Del LocationsConfig
+| 1 /tmp/pardes-snap/lsprelpath/cwd/shade.zig:1:11-15
+| 2 pub const Shade = enum {
+| 3 parent.zig:3:22-26
+| 4 pub fn pick(s: shade.Shade) u8 {
+| /tmp/pardes-snap/lsprelpath/cwd/shade.zig Save Tty Collapse Del TreeContext
+| 1 pub const Shade = enum {
+| 2 verdigris,
+| 3 cinnabar,
+| 4 };
+| 5
+== snap abslook grid=100x35 cursor=32,5
+|3: 1 const shade = @import("../shade.zig");
== style abslook grid=100x35
|0: 0-99 #b2c3b8,#1d2824,
|1: 0-1 d,#887455, 2-2 d,#314738, 3-99 #becfc4,#314738,
-|2: 0-0 d,#496656, 1-1 #000000,#f9cb70,b 2-2 #000000,#1d2824, 3-38 #b2c3b8,#1d2824, 39-49 #d3b0d9,#1d2824, 50-99 #b2c3b8,#1d2824,
+|2: 0-1 d,#add38a, 2-2 d,#314738, 3-38 #becfc4,#314738, 39-49 #dfbce5,#314738, 50-99 #becfc4,#314738,
|3: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-20 #e5eee5,#0d1410, 21-27 #c9a7ed,#0d1410, 28-28 #e5eee5,#0d1410, 29-42 #b8d88a,#0d1410, 43-99 #e5eee5,#0d1410,
|4: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
-|5: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-10 #e5eee5,#0d1410, 11-13 #c9a7ed,#0d1410, 14-99 #e5eee5,#0d1410,
+|5: 0-0 d,#608269, 1-1 d,#0d1410, 2-4 d,#0d1410,b 5-6 #616f64,#0d1410,b 7-10 #e5eee5,#0d1410, 11-13 #c9a7ed,#0d1410, 14-27 #e5eee5,#0d1410, 28-32 #f5f7ee,#3c614a, 33-99 #e5eee5,#0d1410,
|6: 0-0 d,#608269, 1-4 d,#0d1410, 5-10 #59675c,#0d1410, 11-24 #c9a7ed,#0d1410, 25-99 #e5eee5,#0d1410,
-|7: 0-0 d,#608269, 1-4 d,#0d1410, 5-14 #59675c,#0d1410, 15-99 #e5eee5,#0d1410,
+|7: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
|8: 0-0 d,#608269, 1-4 d,#0d1410, 5-10 #59675c,#0d1410, 11-99 #e5eee5,#0d1410,
|9: 0-0 d,#152019, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-99 #e5eee5,#0d1410,
|10: 0-1 d,#496656, 2-2 d,#1d2824, 3-38 #b2c3b8,#1d2824, 39-46 #d3b0d9,#1d2824, 47-99 #b2c3b8,#1d2824,
-|11: 0-0 d,#608269, 1-4 d,#0d1410, 5-55 #59675c,#0d1410, 56-99 #e5eee5,#0d1410,
-|12: 0-0 d,#152019, 1-4 d,#0d1410, 5-55 #59675c,#0d1410, 56-99 #e5eee5,#0d1410,
-|13: 0-1 d,#add38a, 2-2 d,#314738, 3-34 #becfc4,#314738, 35-44 #dfbce5,#314738, 45-99 #becfc4,#314738,
-|14: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-24 #e5eee5,#0d1410, 25-29 #c9a7ed,#0d1410, 30-99 #e5eee5,#0d1410,
-|15: 0-0 d,#608269, 1-1 d,#0d1410, 2-4 d,#0d1410,b 5-6 #616f64,#0d1410,b 7-10 #616f64,#0d1410, 11-19 #f5f7ee,#3c614a, 20-99 #e5eee5,#0d1410,
-|16: 0-0 d,#608269, 1-4 d,#0d1410, 5-10 #59675c,#0d1410, 11-99 #e5eee5,#0d1410,
-|17: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-99 #e5eee5,#0d1410,
-|18: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
-|19: 0-0 d,#608269, 1-99 d,#0d1410,
-|20: 0-0 d,#608269, 1-99 d,#0d1410,
+|11: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
+|12: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-16 #e5eee5,#0d1410, 17-21 #f7e4a5,#5e4923, 22-22 #f7e4a5,#0d1410, 23-24 #e5eee5,#0d1410, 25-29 #c9a7ed,#0d1410, 30-99 #e5eee5,#0d1410,
+|13: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
+|14: 0-0 d,#152019, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-10 #e5eee5,#0d1410, 11-13 #c9a7ed,#0d1410, 14-27 #e5eee5,#0d1410, 28-32 #f7e4a5,#5e4923, 33-99 #e5eee5,#0d1410,
+|15: 0-1 d,#496656, 2-2 d,#1d2824, 3-34 #b2c3b8,#1d2824, 35-44 #d3b0d9,#1d2824, 45-99 #b2c3b8,#1d2824,
+|16: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-16 #e5eee5,#0d1410, 17-21 #f5f7ee,#3c614a, 22-22 #f5f7ee,#0d1410, 23-24 #e5eee5,#0d1410, 25-29 #c9a7ed,#0d1410, 30-99 #e5eee5,#0d1410,
+|17: 0-0 d,#608269, 1-4 d,#0d1410, 5-10 #59675c,#0d1410, 11-99 #e5eee5,#0d1410,
+|18: 0-0 d,#608269, 1-4 d,#0d1410, 5-10 #59675c,#0d1410, 11-99 #e5eee5,#0d1410,
+|19: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-99 #e5eee5,#0d1410,
+|20: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
|21: 0-0 d,#608269, 1-99 d,#0d1410,
|22: 0-0 d,#608269, 1-99 d,#0d1410,
|23: 0-0 d,#608269, 1-99 d,#0d1410,
@@ -57,51 +58,52 @@
|32: 0-0 d,#608269, 1-99 d,#0d1410,
|33: 0-0 d,#608269, 1-99 d,#0d1410,
|34: 0-0 d,#608269, 1-99 d,#0d1410,
-== snap subrow grid=100x35 cursor=16,7
+== snap subrow grid=100x35 cursor=20,16
|Newcol Joincol Find Grep Help Changelog Tutor Dump NextColor Debug Exit
| New Tty Find Grep Joincol Delcol
-|^* /tmp/pardes-snap/lsprelpath/cwd/sub/subdir.zig Save Tty Collapse Del TreeContext
-| 1 const tint = @import("inner/tint.zig");
+| /tmp/pardes-snap/lsprelpath/cwd/sub/subdir.zig Save Tty Collapse Del TreeContext
+| 1 const tint = @import("inner/ti --:--:-- lsp zls ready — /tmp/pardes-snap/lsprelpath/cwd/sub
| 2
| 3 pub fn hue(t: tint.Tint) u8 {
| 4 return switch (t) {
-| 5 .
+| 5
| 6 };
| 7 }
-| /tmp/pardes-snap/lsprelpath/cwd/sub/+Search Save Tty Collapse Del
-| 1 inner/tint.zig:2:5-9 ochre ochre,
-| 2 inner/tint.zig:3:5-10 indigo indigo,
-| 3
-== snap sublook grid=100x35 cursor=15,15
-|2: * /tmp/pardes-snap/lsprelpath/cwd/sub/subdir.zig Save Tty Collapse Del TreeContext
-|13: /tmp/pardes-snap/lsprelpath/cwd/sub/inner/tint.zig Save Tty Collapse Del TreeContext
-|14: 1 pub const Tint = enum {
-|15: 2 ochre,
-|16: 3 indigo,
-|17: 4 };
-|18: 5
+| /tmp/pardes-snap/lsprelpath/cwd/sub/+Search Save Tty Collapse Del LocationsConfig
+| 1 inner/tint.zig:1:11-14
+| 2 pub const Tint = enum {
+| 3 subdir.zig:3:20-23
+| 4 pub fn hue(t: tint.Tint) u8 {
+| /tmp/pardes-snap/lsprelpath/cwd/sub/inner/tint.zig Save Tty Collapse Del TreeContext
+| 1 pub const Tint = enum {
+| 2 ochre,
+| 3 indigo,
+| 4 };
+| 5
+== snap sublook grid=100x35 cursor=29,5
+|3: 1 const tint = @import("inner/tint.zig");
== style sublook grid=100x35
|0: 0-99 #b2c3b8,#1d2824,
|1: 0-1 d,#887455, 2-2 d,#314738, 3-99 #becfc4,#314738,
-|2: 0-0 d,#496656, 1-1 #000000,#f9cb70,b 2-2 #000000,#1d2824, 3-38 #b2c3b8,#1d2824, 39-49 #d3b0d9,#1d2824, 50-99 #b2c3b8,#1d2824,
+|2: 0-1 d,#add38a, 2-2 d,#314738, 3-38 #becfc4,#314738, 39-49 #dfbce5,#314738, 50-99 #becfc4,#314738,
|3: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-19 #e5eee5,#0d1410, 20-26 #c9a7ed,#0d1410, 27-27 #e5eee5,#0d1410, 28-43 #b8d88a,#0d1410, 44-99 #e5eee5,#0d1410,
|4: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
-|5: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-10 #e5eee5,#0d1410, 11-13 #c9a7ed,#0d1410, 14-99 #e5eee5,#0d1410,
+|5: 0-0 d,#608269, 1-1 d,#0d1410, 2-4 d,#0d1410,b 5-6 #616f64,#0d1410,b 7-10 #e5eee5,#0d1410, 11-13 #c9a7ed,#0d1410, 14-25 #e5eee5,#0d1410, 26-29 #f5f7ee,#3c614a, 30-99 #e5eee5,#0d1410,
|6: 0-0 d,#608269, 1-4 d,#0d1410, 5-10 #59675c,#0d1410, 11-24 #c9a7ed,#0d1410, 25-99 #e5eee5,#0d1410,
-|7: 0-0 d,#608269, 1-4 d,#0d1410, 5-14 #59675c,#0d1410, 15-99 #e5eee5,#0d1410,
+|7: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
|8: 0-0 d,#608269, 1-4 d,#0d1410, 5-10 #59675c,#0d1410, 11-99 #e5eee5,#0d1410,
|9: 0-0 d,#152019, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-99 #e5eee5,#0d1410,
|10: 0-1 d,#496656, 2-2 d,#1d2824, 3-38 #b2c3b8,#1d2824, 39-46 #d3b0d9,#1d2824, 47-99 #b2c3b8,#1d2824,
-|11: 0-0 d,#608269, 1-4 d,#0d1410, 5-27 #59675c,#0d1410, 28-99 #e5eee5,#0d1410,
-|12: 0-0 d,#152019, 1-4 d,#0d1410, 5-28 #59675c,#0d1410, 29-99 #e5eee5,#0d1410,
-|13: 0-1 d,#add38a, 2-2 d,#314738, 3-44 #becfc4,#314738, 45-53 #dfbce5,#314738, 54-99 #becfc4,#314738,
-|14: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-23 #e5eee5,#0d1410, 24-28 #c9a7ed,#0d1410, 29-99 #e5eee5,#0d1410,
-|15: 0-0 d,#608269, 1-1 d,#0d1410, 2-4 d,#0d1410,b 5-6 #616f64,#0d1410,b 7-10 #616f64,#0d1410, 11-15 #f5f7ee,#3c614a, 16-99 #e5eee5,#0d1410,
-|16: 0-0 d,#608269, 1-4 d,#0d1410, 5-10 #59675c,#0d1410, 11-99 #e5eee5,#0d1410,
-|17: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-99 #e5eee5,#0d1410,
-|18: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
-|19: 0-0 d,#608269, 1-99 d,#0d1410,
-|20: 0-0 d,#608269, 1-99 d,#0d1410,
+|11: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
+|12: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-16 #e5eee5,#0d1410, 17-20 #f7e4a5,#5e4923, 21-21 #f7e4a5,#0d1410, 22-23 #e5eee5,#0d1410, 24-28 #c9a7ed,#0d1410, 29-99 #e5eee5,#0d1410,
+|13: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
+|14: 0-0 d,#152019, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-10 #e5eee5,#0d1410, 11-13 #c9a7ed,#0d1410, 14-25 #e5eee5,#0d1410, 26-29 #f7e4a5,#5e4923, 30-99 #e5eee5,#0d1410,
+|15: 0-1 d,#496656, 2-2 d,#1d2824, 3-44 #b2c3b8,#1d2824, 45-53 #d3b0d9,#1d2824, 54-99 #b2c3b8,#1d2824,
+|16: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-16 #e5eee5,#0d1410, 17-20 #f5f7ee,#3c614a, 21-21 #f5f7ee,#0d1410, 22-23 #e5eee5,#0d1410, 24-28 #c9a7ed,#0d1410, 29-99 #e5eee5,#0d1410,
+|17: 0-0 d,#608269, 1-4 d,#0d1410, 5-10 #59675c,#0d1410, 11-99 #e5eee5,#0d1410,
+|18: 0-0 d,#608269, 1-4 d,#0d1410, 5-10 #59675c,#0d1410, 11-99 #e5eee5,#0d1410,
+|19: 0-0 d,#608269, 1-4 d,#0d1410, 5-6 #59675c,#0d1410, 7-99 #e5eee5,#0d1410,
+|20: 0-0 d,#608269, 1-4 d,#0d1410, 5-99 #59675c,#0d1410,
|21: 0-0 d,#608269, 1-99 d,#0d1410,
|22: 0-0 d,#608269, 1-99 d,#0d1410,
|23: 0-0 d,#608269, 1-99 d,#0d1410,
@@ -116,4 +118,4 @@
|32: 0-0 d,#608269, 1-99 d,#0d1410,
|33: 0-0 d,#608269, 1-99 d,#0d1410,
|34: 0-0 d,#608269, 1-99 d,#0d1410,
-== snap clicked grid=100x35 cursor=16,16
+== snap clicked grid=100x35 cursor=15,12
diff --git a/test/snapshots/lsprelpath.snap b/test/snapshots/lsprelpath.snap
index 1d662f8a..667c2fc8 100644
--- a/test/snapshots/lsprelpath.snap
+++ b/test/snapshots/lsprelpath.snap
@@ -7,9 +7,8 @@
# to read pushed off the right edge, and a path outside the tree has nothing
# short to be called.
#
-# lspcomplete.snap already covers the easy middle case, a candidate in the SAME
-# directory, which shortens to a bare basename. The two that a prefix strip can
-# actually get wrong are here, one app each:
+# A row in the SAME directory shortens to a bare basename; the two that a
+# prefix strip can actually get wrong are here, one app each, as `gr` rows:
#
# PARENT the enum is one level UP from the asking file, so nothing is
# stripped and the row carries `/tmp/.../cwd/shade.zig`. This is
@@ -33,16 +32,14 @@ file sub/subdir.zig const tint = @import("inner/tint.zig");\n\npub fn hue(t: tin
start 35 100 sub/parent.zig
wait 8000 fn pick
stable 700 20000
-# file line 5 (grid row 6, 1-based click row 7) is the switch's empty body
-press left 8 8
-release left 8 8
+# `gr` on `Shade` in the signature (file line 3, click row 6): its
+# declaration's row is in the parent directory.
+press left 31 6
+release left 31 6
stable 400 5000
-key i
-key end
-text .
-stable 400 5000
-key tab
-wait 15000 cwd/shade.zig:2:
+key g
+key r
+wait 15000 cwd/shade.zig:1:
stable 700 15000
snap absrow
key esc
@@ -58,15 +55,12 @@ snapstyle abslook
start 35 100 sub/subdir.zig
wait 8000 fn hue
stable 700 20000
-press left 8 8
-release left 8 8
-stable 400 5000
-key i
-key end
-text .
+press left 29 6
+release left 29 6
stable 400 5000
-key tab
-wait 15000 inner/tint.zig:2:
+key g
+key r
+wait 15000 inner/tint.zig:1:
stable 700 15000
snap subrow
key esc