From 7ebfa8229768fb12aa4857cb2a1cc72e142cca6c Mon Sep 17 00:00:00 2001 From: Simon Koch-Sultan <126534658+scks1@users.noreply.github.com> Date: Sun, 8 Nov 2026 09:01:24 -0500 Subject: [PATCH] engine: group copy test compares site counts The test compared the pasted shape's connection sites with the original's through zip, which stops at the shorter list. It now checks that both have the same number of sites first. --- crates/engine/src/tests.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/crates/engine/src/tests.rs b/crates/engine/src/tests.rs index 91c603d55..c16583a97 100644 --- a/crates/engine/src/tests.rs +++ b/crates/engine/src/tests.rs @@ -269,6 +269,7 @@ fn a_shape_copied_from_a_group_pastes_where_it_was_drawn() { assert!(s.doc().unwrap().shapes().iter().any(|x| x.id == pasted), "case {n}: {cmd} pastes on the top level"); let d = if same_slide { off } else { 0.0 }; let now = sites(&s, pasted); + assert_eq!(was.len(), now.len(), "case {n}: {cmd}"); assert!( was.iter().zip(&now).all(|(p, q)| (q.x - p.x - d).hypot(q.y - p.y - d) < 1e-6), "case {n}: {cmd} on the same slide {same_slide}: drawn at {was:?}, pasted at {now:?}"