summaryrefslogtreecommitdiff
path: root/test/behaviour
diff options
context:
space:
mode:
Diffstat (limited to 'test/behaviour')
-rw-r--r--test/behaviour/addons.zig11
-rw-r--r--test/behaviour/other_files.zig4
2 files changed, 11 insertions, 4 deletions
diff --git a/test/behaviour/addons.zig b/test/behaviour/addons.zig
index 90f4e383..0b0555c2 100644
--- a/test/behaviour/addons.zig
+++ b/test/behaviour/addons.zig
@@ -411,8 +411,10 @@ test "addons: a picker shows a file of an addon's kind through its kind in the p
try s.expect(body, "the notes\n");
try std.testing.expectEqualStrings(index, try s.read("/index"));
// Enter: the kind's pane where a Look puts it; the reading pane keeps
- // its text.
- try s.keys(" ffseven\n");
+ // its text. (The listing is the next frame's, as for the keyboard.)
+ try s.keys(" ffseven");
+ s.tick();
+ try s.keys("\n");
s.tick();
const opened = try paneOf(&s, "fake");
try std.testing.expect(opened != pane);
@@ -516,7 +518,10 @@ test "addons: Enter on a picture in a picker opens its kind's pane, never its by
defer unload(&s, "image");
const dir = try dirOf(&s, &tmp);
const pane = try s.lookFile(s.at("{s}/notes.txt", .{dir}));
- try s.keys(" ffpic\n");
+ // The listing is the next frame's, as for the keyboard.
+ try s.keys(" ffpic");
+ s.tick();
+ try s.keys("\n");
s.tick();
try s.expect(s.at("/pane/{d}/body", .{pane}), "the notes\n");
const image = try paneOf(&s, "image");
diff --git a/test/behaviour/other_files.zig b/test/behaviour/other_files.zig
index 8a9016bc..95d4de6d 100644
--- a/test/behaviour/other_files.zig
+++ b/test/behaviour/other_files.zig
@@ -35,7 +35,9 @@ test "other-files: kbdin's keys are the user's: SPC f f opens Find's picker in t
_ = try s.lookFile(s.at("{s}/a.txt", .{buf[0..try tmp.dir.realPath(std.testing.io, &buf)]}));
try s.keys(" ff");
try std.testing.expect(std.mem.indexOf(u8, try s.read("/index"), "+Search") == null);
- // Its rows under the tag of the pane typed at, the cursor on the first.
+ // Its rows under the tag of the pane typed at, the cursor on the first,
+ // the next frame, as the keyboard's: the listing is not the write's.
+ s.tick();
_ = try s.where("▶ a.txt");
_ = try s.where(" b.txt");
}