summaryrefslogtreecommitdiff
path: root/src/fs.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/fs.zig')
-rw-r--r--src/fs.zig3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/fs.zig b/src/fs.zig
index 42d761ca..0a4473d6 100644
--- a/src/fs.zig
+++ b/src/fs.zig
@@ -598,7 +598,8 @@ test "virtual body writes can read their input from the same pane" {
const path = try std.fmt.bufPrint(&path_buffer, "/virtual/pane/{d}/body", .{pane.serial});
try write(p, path, pane.file.?.content);
try std.testing.expectEqualStrings("same pane contents\n", pane.file.?.content);
- try std.testing.expectEqual(@as(usize, 2), pane.file.?.history.undo_len);
+ // The truncation and the write are one undo step.
+ try std.testing.expectEqual(@as(usize, 1), pane.file.?.history.undo_len);
const events = &p.panes[p.active].?.fs.events;
try std.testing.expect(std.mem.startsWith(u8, events.peek().?, "ED"));
events.pop();