From 2750e65096d98f7229e6ab7ee157df4928c8942b Mon Sep 17 00:00:00 2001 From: Simon Koch-Sultan <126534658+scks1@users.noreply.github.com> Date: Sun, 8 Nov 2026 09:01:23 -0500 Subject: [PATCH] engine: group duplicate test compares site counts The test compared the copy'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 640c586dc..c66500aea 100644 --- a/crates/engine/src/tests.rs +++ b/crates/engine/src/tests.rs @@ -6559,6 +6559,7 @@ fn duplicating_a_shape_in_a_group_copies_it_into_the_group() { let st = s.doc().unwrap(); let sites = |id| connect::sites_of(&st.doc, &st.selection, st.shapes(), sid(id)).unwrap(); let (p, q) = (sites(from), sites(to)); + assert_eq!(p.len(), q.len(), "{p:?} {q:?}"); let d = q[0] - p[0]; assert!(p.iter().zip(&q).all(|(p, q)| (*q - *p - d).hypot() < 1e-6), "{p:?} {q:?}"); (d.x, d.y)