[tests] cover scale-aware transform

This commit is contained in:
jan 2026-03-09 02:35:35 -07:00
commit 5596e2b1af

View file

@ -64,7 +64,7 @@ def test_apply_transforms() -> None:
t1 = [10, 20, 0, 0]
t2 = [[5, 0, 0, 0], [0, 5, 0, 0]]
combined = apply_transforms(t1, t2)
assert_equal(combined, [[15, 20, 0, 0], [10, 25, 0, 0]])
assert_equal(combined, [[15, 20, 0, 0, 1], [10, 25, 0, 0, 1]])
def test_apply_transforms_advanced() -> None:
@ -80,4 +80,4 @@ def test_apply_transforms_advanced() -> None:
# 1. mirror inner y if outer mirrored: (10, 0) -> (10, 0)
# 2. rotate by outer rotation (pi/2): (10, 0) -> (0, 10)
# 3. add outer offset (0, 0) -> (0, 10)
assert_allclose(combined[0], [0, 10, pi / 2, 1], atol=1e-10)
assert_allclose(combined[0], [0, 10, pi / 2, 1, 1], atol=1e-10)