T40: review round 2: the session's title comes from the tap alone, in the output's order, so the row, the window and a notification name it alike: OSC 0 and 2 read as vte splits them, 15 parts past the number, and up to 65536 bytes; alacritty's title events, which come later, pass by, and a full reset no longer sets the options again to send one
CI / platforms (ubuntu-24.04) (push) Successful in 1m31s
CI / platforms (windows-latest) (push) Successful in 1m37s
CI / macos (push) Canceled after 0s

This commit is contained in:
ZacharyZhang-NY committed 2026-10-17 16:17:55 -04:00
1 parent 22752a28db
commit 140c2a5741
8 files changed
+77 -40

No files matched your search

+19
View File
@@ -259,3 +259,22 @@ fn finds_the_title_stack_s_push_and_pop_as_vte_reads_them() {
["PUSH", "2;t", "POP"]
);
}
#[test]
fn a_title_s_body_holds_65536_bytes_and_another_s_4096() {
let osc = |number: &str, length: usize| {
[
format!("\x1b]{number};").as_bytes(),
&vec![b'a'; length],
b"\x07",
]
.concat()
};
let longest = scan(&[&osc("2", titles::LONGEST - 2)]);
assert_eq!(longest.concat().len(), titles::LONGEST);
assert!(scan(&[&osc("0", titles::LONGEST - 1)]).is_empty());
assert!(
scan(&[&osc("7", MOST - 1)]).is_empty(),
"another stays at 4096"
);
}