mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-16 16:56:09 +03:00
terminal: save/restore cursor doesn't modify hyperlink state
This commit is contained in:
@ -8306,6 +8306,19 @@ test "Terminal: saveCursor protected pen" {
|
||||
try testing.expect(t.screen.cursor.protected);
|
||||
}
|
||||
|
||||
test "Terminal: saveCursor doesn't modify hyperlink state" {
|
||||
const alloc = testing.allocator;
|
||||
var t = try init(alloc, .{ .cols = 3, .rows = 3 });
|
||||
defer t.deinit(alloc);
|
||||
|
||||
try t.screen.startHyperlink("http://example.com", null);
|
||||
const id = t.screen.cursor.hyperlink_id;
|
||||
t.saveCursor();
|
||||
try testing.expectEqual(id, t.screen.cursor.hyperlink_id);
|
||||
try t.restoreCursor();
|
||||
try testing.expectEqual(id, t.screen.cursor.hyperlink_id);
|
||||
}
|
||||
|
||||
test "Terminal: setProtectedMode" {
|
||||
const alloc = testing.allocator;
|
||||
var t = try init(alloc, .{ .cols = 3, .rows = 3 });
|
||||
|
Reference in New Issue
Block a user