summaryrefslogtreecommitdiff
path: root/test/snapshots/grep.snap
diff options
context:
space:
mode:
Diffstat (limited to 'test/snapshots/grep.snap')
-rw-r--r--test/snapshots/grep.snap32
1 files changed, 20 insertions, 12 deletions
diff --git a/test/snapshots/grep.snap b/test/snapshots/grep.snap
index 817f613f..1d3efc9e 100644
--- a/test/snapshots/grep.snap
+++ b/test/snapshots/grep.snap
@@ -6,8 +6,9 @@
# looking it SELECTS the hit — with the path RELATIVE to the directory
# of the pane that asked — the same directory its results buffer is named in,
# so the short name resolves; only a hit from outside that tree stays absolute.
-# n/N walk the rows like any other result list, and a row pointing into a file
-# nothing has open yet opens it.
+# n/N SELECT the next/prev row like any other result list and open nothing;
+# Enter looks what they leave selected, and a row pointing into a file nothing
+# has open yet opens it.
dirmk sub
file a.txt hello TARGET one\nnothing here\nlast TARGET line
file sub/b.txt deep\nTARGET inside sub
@@ -44,25 +45,32 @@ key enter
wait 10000 sub/b.txt:2:1
stable 700 15000
snap results
-# n looks the first row: absolute path, line 1, columns 7..12 (`TARGET`), and
-# those six cells come up selected
+# n selects the first row and Enter looks it: absolute path, line 1, columns
+# 7..12 (`TARGET`), and those six cells come up selected
key n
+key enter
stable 700 15000
snap first
-# ...and stepping on into sub/b.txt opens the file nothing had open
+# ...and stepping on into sub/b.txt, then looking it, opens the file nothing
+# had open
key n
+key enter
stable 700 15000
key n
+key enter
wait 10000 TARGET inside sub
stable 700 15000
snap opened-hit
-# a pattern nothing holds: an empty list of its own, n has nowhere to go.
-# Armed from the LEADER, not the topbar word: the n above left the hit
-# SELECTED in a.txt (a ranged result row is one a look selects), and a topbar
-# execute chords whatever is selected into its argument — so a middle-click
-# here would run `Grep TARGET` and never ask for a pattern at all. The leader
-# path runs the builtin with no argument, which is what this step is about; the
-# chord itself is the last two snaps below.
+# a pattern nothing holds: an empty list of its own, with nothing in it for n
+# to stop on — so the ring carries that step back into the TARGET list. The
+# look above is why both of those read the way they do: it left the cursor in
+# sub/b.txt, so the empty list is named in sub/ rather than cwd/, and it left
+# the hit SELECTED there (a ranged result row is one a look selects).
+# Armed from the LEADER, not the topbar word, because of that selection: a
+# topbar execute chords whatever is selected into its argument, so a
+# middle-click here would run `Grep TARGET` and never ask for a pattern at
+# all. The leader path runs the builtin with no argument, which is what this
+# step is about; the chord itself is the last two snaps below.
key space
key f
key g