fix: preserve review comments across unrelated edits

This commit is contained in:
Valdemar Lorenzen
2026-10-20 14:58:56 +02:00
parent 2727425518
commit 31203889bb
10 changed files with 422 additions and 147 deletions
+1 -1
View File
@@ -3225,7 +3225,7 @@ fn local_review_markers_reject_stale_identity_text_and_rename_paths() {
let anchor = &mut diff.local_review.document.comments[0].anchor;
match mismatch {
"revision" => anchor.revision.push_str("-newer"),
"content" => anchor.content.push('\n'),
"content" => anchor.content.replace_range(..1, "X"),
"path" => anchor.path = "new.txt".into(),
"side" => anchor.side = crate::review::Side::After,
"root" => diff.local_review.document.root = "another-repository".into(),