╭ changed ────────╮ │src/test/undo.zig│ ╰─────────────────╯ ╭───────────╮ │← all files│ ╰───────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────╮ │17 defer repo.deinit(io, allocator); │ │18 var arena = std.heap.ArenaAllocator.init(allocator); │ │19 defer arena.deinit(); │ │20 - const initial = try Undo.init(opts, &arena, &repo, "", null); │ │20 + const initial = try Undo.init(opts, &arena, &repo, null, "", null); │ │21 try std.testing.expectEqual(1, initial.count); │ │22 for (0..25) |index| { │ │23 const value = try std.fmt.allocPrint(arena.allocator(), "{d}", .{index});│ ╰─────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────╮ │24 try repo.addConfig(io, allocator, .{ .name = "undo.value", .value = value });│ │25 } │ │26 - const first = try Undo.init(opts, &arena, &repo, "", null); │ │26 + const first = try Undo.init(opts, &arena, &repo, null, "", null); │ │27 try std.testing.expectEqual(20, first.items.len); │ │28 try std.testing.expectEqual(25, first.items[0].index); │ │29 - const second = try Undo.init(opts, &arena, &repo, "", first.next); │ │29 + const second = try Undo.init(opts, &arena, &repo, null, "", first.next); │ │30 try std.testing.expectEqual(6, second.items.len); │ │31 try std.testing.expectEqual(5, second.items[0].index); │ │32 try std.testing.expectEqual(0, second.items[5].index); │ ╰─────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────╮ │33 try std.testing.expectEqual(null, second.next); │ │34 - try std.testing.expectError(error.NotFound, Undo.init(opts, &arena, &repo, "", 26)); │ │34 + try std.testing.expectError(error.NotFound, Undo.init(opts, &arena, &repo, null, "", 26));│ │35 try std.testing.expectError(error.InvalidHistoryIndex, repo.undo(io, 0)); │ │36 try std.testing.expectError(error.InvalidHistoryIndex, repo.undo(io, 26)); │ │37 │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭───────────────────────────────────────────────────────────────────────────╮ │40 try expectConfig(&repo, "23"); │ │41 try repo.undo(io, 10); │ │42 try expectConfig(&repo, "8"); │ │43 - const undone = try Undo.init(opts, &arena, &repo, "", null); │ │43 + const undone = try Undo.init(opts, &arena, &repo, null, "", null); │ │44 try std.testing.expectEqual(28, undone.count); │ │45 try std.testing.expectEqualStrings("undo", undone.items[0].action);│ │46 try repo.undo(io, undone.items[0].index); │ ╰───────────────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────╮ │121 var repo = try xit.repo.Repo(.xit, .{}).open(io, allocator, .{ .path = path });│ │122 defer repo.deinit(io, allocator); │ │123 try expectConfig(&repo, "first"); │ │124 - const data = try Undo.init(.{}, &arena, &repo, "alice/demo", null); │ │124 + const data = try Undo.init(.{}, &arena, &repo, null, "alice/demo", null); │ │125 try std.testing.expectEqualStrings("undo", data.items[0].action); │ │126 } │ │127 // keep the old session/page moment, but transfer ownership to the writer. │ ╰────────────────────────────────────────────────────────────────────────────────────────────╯ ╭───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │183 var repo = try xit.repo.Repo(.xit, opts).init(io, allocator, .{ .path = path }); │ │184 defer repo.deinit(io, allocator); │ │185 _ = try repo.commitAtRef(io, allocator, .{ .message = "example commit" }, null, .{ .kind = .head, .name = "master" });│ │186 - const data = try Undo.init(opts, &arena, &repo, "", null); │ │186 + const data = try Undo.init(opts, &arena, &repo, null, "", null); │ │187 try std.testing.expect(std.mem.startsWith(u8, data.items[0].description, "commit -m \"example commit\"")); │ │188 } │ │189 │ ╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯